# Generated by Django 2.2.5 on 2019-11-17 17:06

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


class Migration(migrations.Migration):

    initial = True

    dependencies = [
        ('ingredientes', '0001_initial'),
        ('usuarios', '0001_initial'),
    ]

    operations = [
        migrations.CreateModel(
            name='Pizza',
            fields=[
                ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
                ('nombre', models.CharField(max_length=50)),
                ('valor', models.BigIntegerField()),
                ('descripcion', models.CharField(default='', max_length=250)),
                ('especial', models.BooleanField(default=True)),
                ('enventa', models.BooleanField(default=True)),
                ('imagen', models.FileField(upload_to='media/pizzas/', blank=True, null=True)),
                ('ingrediente', models.ManyToManyField(to='ingredientes.Ingrediente')),
            ],
        ),
        migrations.CreateModel(
            name='Factura',
            fields=[
                ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
                ('direccion', models.TextField()),
                ('fecha_creacion', models.DateField(auto_now_add=True)),
                ('hora_creacion', models.TimeField(auto_now_add=True)),
                ('efectivo', models.FloatField(default=0)),
                ('estado_Factura', models.IntegerField(default=0)),
                ('cliente', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, to='usuarios.Usuario')),
            ],
        ),
        migrations.CreateModel(
            name='Detalle',
            fields=[
                ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
                ('cantidad', models.PositiveIntegerField(default=1)),
                ('precio', models.FloatField()),
                ('factura', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, to='pizzas.Factura')),
                ('producto', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, to='pizzas.Pizza')),
            ],
        ),
    ]
