# Generated by Django 2.0.3 on 2018-03-29 13:33

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


class Migration(migrations.Migration):

    initial = True

    dependencies = [
    ]

    operations = [
        migrations.CreateModel(
            name='Product',
            fields=[
                ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
                ('title', models.CharField(max_length=64)),
            ],
        ),
        migrations.CreateModel(
            name='Vitamin',
            fields=[
                ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
                ('title', models.CharField(max_length=64)),
                ('code', models.CharField(blank=True, max_length=9)),
                ('description', models.TextField(blank=True)),
                ('rdi', models.DecimalField(blank=True, decimal_places=2, max_digits=7, null=True)),
                ('unit', models.CharField(choices=[('mkg', 'мкг'), ('mg', 'мг')], max_length=3)),
            ],
        ),
        migrations.CreateModel(
            name='VitaminInProduct',
            fields=[
                ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
                ('amount', models.DecimalField(decimal_places=2, max_digits=7)),
                ('unit', models.CharField(choices=[('mkg', 'мкг'), ('mg', 'мг'), ('g', 'г'), ('kg', 'кг')], max_length=3)),
                ('product', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, to='vitamin.Product')),
                ('vitamin', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, to='vitamin.Vitamin')),
            ],
        ),
    ]
