# Generated by Django 2.2.16 on 2020-11-08 15:38

from django.db import migrations, models
import django.db.models.deletion


class Migration(migrations.Migration):

    initial = True

    dependencies = [
        ('catalogue', '0030_collection_role'),
    ]

    operations = [
        migrations.CreateModel(
            name='Entity',
            fields=[
                ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
                ('uri', models.CharField(db_index=True, max_length=255, unique=True)),
                ('label', models.CharField(blank=True, max_length=1024)),
                ('description', models.CharField(blank=True, max_length=2048)),
                ('wikipedia_link', models.CharField(blank=True, max_length=1024)),
                ('lat', models.FloatField(blank=True, null=True)),
                ('lon', models.FloatField(blank=True, null=True)),
                ('images', models.TextField(blank=True)),
            ],
        ),
        migrations.CreateModel(
            name='Reference',
            fields=[
                ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
                ('first_section', models.CharField(max_length=255)),
                ('book', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, to='catalogue.Book')),
                ('entity', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, to='references.Entity')),
            ],
            options={
                'unique_together': {('book', 'entity')},
            },
        ),
    ]
