# Generated by Django 3.1.5 on 2021-01-19 13:05

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


class Migration(migrations.Migration):

    dependencies = [
        ('library', '0007_auto_20210114_0437'),
    ]

    operations = [
        migrations.CreateModel(
            name='Author',
            fields=[
                ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
                ('name', models.CharField(max_length=50, verbose_name='ФИО автора ')),
                ('field', models.CharField(max_length=500, verbose_name='Книга ')),
            ],
        ),
        migrations.CreateModel(
            name='Book',
            fields=[
                ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
                ('name', models.CharField(max_length=50, verbose_name='Название книги')),
                ('quantity', models.IntegerField(max_length=1000, verbose_name='Количество')),
                ('author', models.CharField(max_length=50, verbose_name='Автор')),
                ('description', models.CharField(max_length=1000, verbose_name='Описание')),
            ],
        ),
        migrations.CreateModel(
            name='Library',
            fields=[
                ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
                ('name', models.CharField(max_length=50, verbose_name='Марка автомобиля')),
                ('number', models.CharField(default=1, max_length=50, verbose_name='Контактный номер')),
                ('Author', models.ManyToManyField(blank=True, to='library.Author')),
            ],
        ),
        migrations.RemoveField(
            model_name='dealer',
            name='suppliers',
        ),
        migrations.DeleteModel(
            name='Car_model',
        ),
        migrations.DeleteModel(
            name='Dealer',
        ),
        migrations.DeleteModel(
            name='Supplier',
        ),
        migrations.AddField(
            model_name='book',
            name='library',
            field=models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, to='library.library'),
        ),
    ]
