# -*- coding: utf-8 -*-
# Generated by Django 1.11.7 on 2017-11-29 05:08
from __future__ import unicode_literals

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


class Migration(migrations.Migration):

    initial = True

    dependencies = [
        ('contenttypes', '0002_remove_content_type_name'),
        migrations.swappable_dependency(settings.AUTH_USER_MODEL),
    ]

    operations = [
        migrations.CreateModel(
            name='Comment',
            fields=[
                ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
                ('text', models.TextField(verbose_name='Текст')),
                ('created', models.DateTimeField(auto_now_add=True, verbose_name='Дата создания')),
                ('object_id', models.PositiveIntegerField(verbose_name='Идентификатор объекта')),
                ('content_type', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, to='contenttypes.ContentType', verbose_name='Тип содержимого')),
                ('user', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, to=settings.AUTH_USER_MODEL, verbose_name='Пользователь')),
            ],
            options={
                'verbose_name': 'Комментарий',
                'verbose_name_plural': 'Комментарии',
            },
        ),
        migrations.CreateModel(
            name='Film',
            fields=[
                ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
                ('poster', models.ImageField(blank=True, upload_to='posters/', verbose_name='Постер фильма')),
                ('title_film', models.CharField(max_length=255, verbose_name='Название:')),
                ('year_pub', models.DateField(verbose_name='Выход в прокат:')),
                ('budget', models.PositiveIntegerField(verbose_name='Бюджет:')),
                ('fees', models.PositiveIntegerField(verbose_name='Сборы:')),
                ('duration', models.PositiveSmallIntegerField(verbose_name='Продолжительность, мин.:')),
                ('content', models.TextField(blank=True, max_length=10000, verbose_name='Сюжет:')),
            ],
            options={
                'verbose_name': 'Фильм',
                'verbose_name_plural': 'Фильмы',
            },
        ),
        migrations.CreateModel(
            name='Genres',
            fields=[
                ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
                ('genres', models.TextField(verbose_name='Жанр')),
            ],
            options={
                'verbose_name': 'Жанр',
                'verbose_name_plural': 'Жанры',
            },
        ),
        migrations.CreateModel(
            name='Producer',
            fields=[
                ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
                ('full_name', models.CharField(max_length=255, verbose_name='Полное имя')),
            ],
            options={
                'verbose_name': 'Продюсер',
                'verbose_name_plural': 'Продюсеры',
            },
        ),
        migrations.AddField(
            model_name='film',
            name='genre',
            field=models.ManyToManyField(to='films.Genres', verbose_name='Жанр:'),
        ),
        migrations.AddField(
            model_name='film',
            name='producer',
            field=models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, to='films.Producer', verbose_name='Продюсер:'),
        ),
    ]
