# Generated by Django 2.2.6 on 2019-10-09 07:14

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


class Migration(migrations.Migration):

    dependencies = [("shop", "0005_category_count")]

    operations = [
        migrations.CreateModel(
            name="Address",
            fields=[
                (
                    "id",
                    models.AutoField(
                        auto_created=True,
                        primary_key=True,
                        serialize=False,
                        verbose_name="ID",
                    ),
                ),
                ("address1", models.CharField(max_length=50)),
                ("address2", models.CharField(blank=True, max_length=50, null=True)),
                ("address3", models.CharField(blank=True, max_length=50, null=True)),
                ("town", models.CharField(max_length=50)),
                ("post_code", models.CharField(blank=True, max_length=15, null=True)),
                ("country", models.CharField(blank=True, max_length=50, null=True)),
            ],
        ),
        migrations.CreateModel(
            name="Contact",
            fields=[
                (
                    "id",
                    models.AutoField(
                        auto_created=True,
                        primary_key=True,
                        serialize=False,
                        verbose_name="ID",
                    ),
                ),
                ("title", models.CharField(blank=True, max_length=20, null=True)),
                ("first_name", models.CharField(blank=True, max_length=30, null=True)),
                ("last_name", models.CharField(max_length=30)),
                ("company", models.CharField(blank=True, max_length=50, null=True)),
                ("work_phone", models.CharField(blank=True, max_length=20, null=True)),
                (
                    "mobile_phone",
                    models.CharField(blank=True, max_length=20, null=True),
                ),
                ("email", models.EmailField(blank=True, max_length=80, null=True)),
                ("notes", models.CharField(max_length=1000)),
                ("mail_consent", models.BooleanField(default=False)),
                (
                    "address",
                    models.ForeignKey(
                        null=True,
                        on_delete=django.db.models.deletion.SET_NULL,
                        to="shop.Address",
                    ),
                ),
            ],
        ),
        migrations.CreateModel(
            name="Enquiry",
            fields=[
                (
                    "id",
                    models.AutoField(
                        auto_created=True,
                        primary_key=True,
                        serialize=False,
                        verbose_name="ID",
                    ),
                ),
                ("date", models.DateField(auto_now_add=True)),
                ("message", models.TextField()),
                ("closed", models.BooleanField(default=False)),
                (
                    "contact",
                    models.ForeignKey(
                        null=True,
                        on_delete=django.db.models.deletion.SET_NULL,
                        to="shop.Contact",
                    ),
                ),
                ("items", models.ManyToManyField(to="shop.Item")),
            ],
        ),
    ]
