# Generated by Django 2.2.5 on 2020-06-15 07:20

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


class Migration(migrations.Migration):

    dependencies = [
        ('bible', '0001_initial'),
    ]

    operations = [
        migrations.CreateModel(
            name='ReferenceVerse',
            fields=[
                ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
                ('verse_number', models.PositiveIntegerField()),
                ('chapter_number', models.PositiveIntegerField()),
                ('book_number', models.PositiveIntegerField()),
            ],
            options={
                'unique_together': {('verse_number', 'chapter_number', 'book_number')},
            },
        ),
        migrations.CreateModel(
            name='Reference',
            fields=[
                ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
                ('reference_from', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, related_name='references_from', to='bible.ReferenceVerse')),
                ('reference_to', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, related_name='references_to', to='bible.ReferenceVerse')),
                ('verse', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, related_name='references', to='bible.ReferenceVerse')),
            ],
            options={
                'unique_together': {('verse', 'reference_from', 'reference_to')},
            },
        ),
    ]
