# Generated by Django 3.2 on 2021-05-04 17:17

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


class Migration(migrations.Migration):

    initial = True

    dependencies = [
    ]

    operations = [
        migrations.CreateModel(
            name='Account',
            fields=[
                ('AccountID', models.IntegerField(primary_key=True, serialize=False)),
                ('AccountName', models.CharField(max_length=255)),
                ('AccountPass', models.CharField(max_length=255)),
                ('ProfilePic', models.CharField(max_length=255)),
                ('DateOfBirth', models.DateTimeField(null=True)),
            ],
        ),
        migrations.CreateModel(
            name='Country',
            fields=[
                ('CountryID', models.IntegerField(primary_key=True, serialize=False)),
                ('CountryName', models.CharField(max_length=255)),
            ],
        ),
        migrations.CreateModel(
            name='ItemCategory',
            fields=[
                ('CategoryID', models.IntegerField(primary_key=True, serialize=False)),
                ('CategoryTag', models.CharField(max_length=255)),
            ],
        ),
        migrations.CreateModel(
            name='Manufacturer',
            fields=[
                ('ManID', models.IntegerField(primary_key=True, serialize=False)),
                ('Name', models.CharField(max_length=255)),
            ],
        ),
        migrations.CreateModel(
            name='Items',
            fields=[
                ('ItemID', models.IntegerField(primary_key=True, serialize=True)),
                ('ManID', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, to='main.manufacturer')),
                ('Quantity_available', models.IntegerField()),
                ('Price', models.IntegerField()),
                ('Name', models.CharField(max_length=255)),
                ('Description', models.CharField(max_length=9999, blank=True)),
                ('Image', models.CharField(max_length=255, null=True)),
                ('Tags', models.ManyToManyField(to='main.ItemCategory'))
            ]
        ),
        migrations.CreateModel(
            name='OrderContains',
            fields=[
                ('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
                ('Quantity', models.IntegerField()),
                ('ItemID', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, to='main.items')),
            ],
        ),
        migrations.CreateModel(
            name='Order',
            fields=[
                ('OrderID', models.IntegerField(primary_key=True, serialize=False)),
                ('AccountID', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, to='main.account')),
                ('ItemsInOrder', models.ManyToManyField(to='main.Items')),
            ],
        ),
        migrations.CreateModel(
            name='ManufacturerLogo',
            fields=[
                ('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
                ('Image', models.CharField(max_length=9999)),
                ('ManID', models.OneToOneField(on_delete=django.db.models.deletion.CASCADE, to='main.manufacturer')),
            ],
        ),
        migrations.CreateModel(
            name='UserInfo',
            fields=[
                ('AccountConnected', models.OneToOneField(on_delete=django.db.models.deletion.CASCADE, primary_key=True, serialize=False, to='main.account')),
                ('FirstName', models.CharField(max_length=255)),
                ('LastName', models.CharField(max_length=255)),
                ('City', models.CharField(max_length=255)),
                ('PostalCode', models.CharField(max_length=15)),
                ('Address', models.CharField(max_length=255)),
                ('HouseNum', models.IntegerField()),
                ('MobilePhone', models.CharField(max_length=63)),
                ('Email', models.CharField(max_length=255)),
                ('SSN', models.CharField(max_length=255)),
                ('Country', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, to='main.country')),
            ],
        ),
    ]
