# Generated by Django 4.0.3 on 2022-03-13 10:21

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


class Migration(migrations.Migration):

    initial = True

    dependencies = [
    ]

    operations = [
        migrations.CreateModel(
            name='IngredientCalories',
            fields=[
                ('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
                ('ingredient_name', models.CharField(max_length=256)),
                ('ingredient_calories', models.FloatField()),
                ('alergens', models.CharField(blank=True, choices=[('GLUTEN', 'Gluten'), ('EGGS', 'Eggs'), ('LACTOSE', 'lactose'), ('NUTS', 'Nuts'), ('PEANUTS', 'Peanuts'), ('SESAME SEEDS', 'Sesame Seeds'), ('SOY', 'Soy')], max_length=128, null=True)),
            ],
            options={
                'db_table': 'ingredient_calories',
            },
        ),
        migrations.CreateModel(
            name='Recipe',
            fields=[
                ('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
                ('recipe_category', models.CharField(blank=True, choices=[('BREAD & DOUGH', 'bread & dough'), ('CAKES', 'cakes'), ('COOKIES & BISCUITS', 'cookies & biscuits'), ('CUPCAKES & MUFFINS', 'cupcakes & muffins'), ('DESSERTS', 'desserts'), ('PANCAKES & CREPES', 'pancakes & crepes'), ('DESSERTS, PIES & TARTS', 'desserts, pies & tarts')], max_length=128, null=True)),
                ('recipe_name', models.CharField(max_length=256)),
                ('recipe_description', models.CharField(max_length=512)),
                ('preparation_time', models.PositiveIntegerField()),
                ('recipe_content', models.CharField(max_length=2048)),
                ('pic_url', models.URLField(blank=True, null=True)),
                ('difficulty_level', models.PositiveSmallIntegerField(validators=[django.core.validators.MinValueValidator(1), django.core.validators.MaxValueValidator(5)])),
                ('is_deleted', models.BooleanField(default=False)),
            ],
            options={
                'db_table': 'recipe',
            },
        ),
        migrations.CreateModel(
            name='User',
            fields=[
                ('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
                ('name', models.CharField(max_length=128)),
                ('email', models.CharField(max_length=128)),
                ('address', models.CharField(max_length=256)),
                ('date_joined', models.DateField(auto_now_add=True)),
            ],
            options={
                'db_table': 'user',
            },
        ),
        migrations.CreateModel(
            name='RecipeReviews',
            fields=[
                ('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
                ('review_date', models.DateField(auto_now_add=True)),
                ('review_title', models.CharField(max_length=256)),
                ('review_content', models.CharField(max_length=1024)),
                ('review_grade', models.PositiveSmallIntegerField(validators=[django.core.validators.MinValueValidator(1), django.core.validators.MaxValueValidator(10)])),
                ('recipe_id', models.ForeignKey(on_delete=django.db.models.deletion.PROTECT, to='recipes_and_more_app.recipe')),
                ('user_id', models.ForeignKey(on_delete=django.db.models.deletion.PROTECT, to='recipes_and_more_app.user')),
            ],
            options={
                'db_table': 'recipe_reviews',
            },
        ),
        migrations.CreateModel(
            name='ReceiptIngredient',
            fields=[
                ('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
                ('amount', models.FloatField()),
                ('amount_type', models.CharField(blank=True, choices=[('BREAD & DOUGH', 'Gluten'), ('COOKIES & BISCUITS', 'Eggs'), ('CUPCAKES & MUFFINS', 'lactose'), ('CAKES', 'Nuts'), ('DESSERTS', 'Peanuts'), ('PANCAKES & CREPES', 'Sesame Seeds'), ('PANCAKES & CREPES', 'Soy')], max_length=128, null=True)),
                ('ingredient_calories', models.ForeignKey(on_delete=django.db.models.deletion.PROTECT, to='recipes_and_more_app.ingredientcalories')),
                ('recipe', models.ForeignKey(on_delete=django.db.models.deletion.PROTECT, to='recipes_and_more_app.recipe')),
            ],
        ),
    ]
