# Generated by Django 2.2 on 2020-12-03 15:51

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


class Migration(migrations.Migration):

    initial = True

    dependencies = [
    ]

    operations = [
        migrations.CreateModel(
            name='Genre',
            fields=[
                ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
                ('name', models.CharField(max_length=100)),
            ],
        ),
        migrations.CreateModel(
            name='Poster',
            fields=[
                ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
                ('poster_url', models.ImageField(max_length=255, upload_to='poster/')),
            ],
        ),
        migrations.CreateModel(
            name='Movie',
            fields=[
                ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
                ('name', models.CharField(max_length=100)),
                ('director', models.CharField(max_length=100)),
                ('popularity', models.CharField(max_length=100)),
                ('imdb_score', models.FloatField()),
                ('genre', models.ManyToManyField(related_name='movies', to='movieapp.Genre')),
                ('poster_id', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, to='movieapp.Poster')),
            ],
        ),
    ]
