# Generated by Django 3.0 on 2020-10-10 17:19

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


class Migration(migrations.Migration):

    initial = True

    dependencies = [
    ]

    operations = [
        migrations.CreateModel(
            name='Category',
            fields=[
                ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
                ('category_name', models.CharField(max_length=128)),
                ('category_desc', models.CharField(blank=True, max_length=256)),
            ],
        ),
        migrations.CreateModel(
            name='Product',
            fields=[
                ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
                ('product_id', models.CharField(max_length=64)),
                ('product_name', models.CharField(max_length=256)),
                ('merchant_name', models.CharField(max_length=64)),
                ('listing_price', models.FloatField(default=1.0)),
                ('sale_price', models.FloatField(default=1.0)),
                ('discount', models.FloatField(default=0)),
                ('brand', models.CharField(max_length=128)),
                ('description', models.CharField(max_length=512)),
                ('rating', models.FloatField(default=0)),
                ('reviews', models.CharField(max_length=1024)),
                ('url', models.CharField(max_length=512)),
                ('category_id', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, to='products.Category')),
            ],
        ),
        migrations.CreateModel(
            name='Review',
            fields=[
                ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
                ('recommended_rank', models.FloatField(default=0)),
                ('comment', models.CharField(blank=True, max_length=256, null=True)),
                ('product_id', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, to='products.Product')),
            ],
        ),
    ]
