# Generated by Django 3.1.4 on 2021-08-12 02:15

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


class Migration(migrations.Migration):

    initial = True

    dependencies = [
        migrations.swappable_dependency(settings.AUTH_USER_MODEL),
    ]

    operations = [
        migrations.CreateModel(
            name='Customer',
            fields=[
                ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
                ('name', models.CharField(blank=True, max_length=200, null=True)),
                ('date_created', models.DateTimeField(auto_now_add=True, null=True)),
                ('email', models.CharField(blank=True, max_length=200, null=True)),
                ('user', models.OneToOneField(blank=True, null=True, on_delete=django.db.models.deletion.CASCADE, to=settings.AUTH_USER_MODEL)),
            ],
        ),
        migrations.CreateModel(
            name='Order',
            fields=[
                ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
                ('date_ordered', models.DateTimeField(auto_now_add=True)),
                ('date_deliverd', models.DateTimeField(auto_now=True)),
                ('complete', models.BooleanField(default=False)),
                ('transaction_id', models.CharField(max_length=200)),
                ('is_deliverd', models.BooleanField(blank=True, default=False)),
                ('customer', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, to='EcommerceApp.customer')),
            ],
        ),
        migrations.CreateModel(
            name='Product',
            fields=[
                ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
                ('name', models.CharField(max_length=200)),
                ('price', models.FloatField()),
                ('image', models.ImageField(upload_to='')),
                ('image1', models.ImageField(blank=True, null=True, upload_to='')),
                ('image2', models.ImageField(blank=True, null=True, upload_to='')),
                ('image3', models.ImageField(blank=True, null=True, upload_to='')),
                ('image4', models.ImageField(blank=True, null=True, upload_to='')),
                ('image5', models.ImageField(blank=True, null=True, upload_to='')),
                ('image6', models.ImageField(blank=True, null=True, upload_to='')),
                ('image7', models.ImageField(blank=True, null=True, upload_to='')),
                ('image8', models.ImageField(blank=True, null=True, upload_to='')),
                ('image9', models.ImageField(blank=True, null=True, upload_to='')),
                ('image10', models.ImageField(blank=True, null=True, upload_to='')),
                ('category', models.CharField(choices=[('paithani', 'paithani'), ('semi_paithani', 'semi_paithani'), ('silk_saree', 'silk_saree'), ('traditional', 'traditional'), ('western', 'western')], max_length=20)),
                ('is_avaible', models.BooleanField(default=True)),
                ('fabric', models.CharField(blank=True, max_length=256, null=True)),
                ('pattern', models.CharField(blank=True, max_length=256, null=True)),
                ('color', models.CharField(blank=True, max_length=256, null=True)),
                ('style', models.CharField(blank=True, max_length=256, null=True)),
                ('in_the_pack', models.IntegerField(blank=True, null=True)),
            ],
        ),
        migrations.CreateModel(
            name='ShippingAddress',
            fields=[
                ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
                ('phone', models.CharField(max_length=200)),
                ('address', models.TextField()),
                ('zipcode', models.IntegerField()),
                ('city', models.CharField(max_length=80)),
                ('state', models.CharField(max_length=80)),
                ('date_added', models.DateTimeField(auto_now_add=True)),
                ('customer', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, to='EcommerceApp.customer')),
            ],
        ),
        migrations.CreateModel(
            name='ProductReview',
            fields=[
                ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
                ('review', models.CharField(blank=True, max_length=256, null=True)),
                ('stars', models.PositiveIntegerField(blank=True, null=True)),
                ('date', models.DateTimeField(auto_now_add=True, null=True)),
                ('customer', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, to='EcommerceApp.customer')),
                ('product', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, to='EcommerceApp.product')),
            ],
        ),
        migrations.CreateModel(
            name='OrderItem',
            fields=[
                ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
                ('quantity', models.IntegerField(default=0)),
                ('date_ordered', models.DateTimeField(auto_now_add=True)),
                ('order', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, to='EcommerceApp.order')),
                ('product', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, to='EcommerceApp.product')),
            ],
        ),
    ]
