# -*- coding: utf-8 -*-
# Generated by Django 1.11.24 on 2020-09-10 08:46
from __future__ import unicode_literals

from django.conf import settings
from django.db import migrations, models
from django.db.migrations.operations.special import SeparateDatabaseAndState
import django.db.models.deletion


class Migration(migrations.Migration):
    dependencies = [
        migrations.swappable_dependency(settings.AUTH_USER_MODEL),
        ("common", "0001_initial"),
    ]

    operations = [
        migrations.SeparateDatabaseAndState(
            state_operations=[
                migrations.CreateModel(
                    name="EmailVerification",
                    fields=[
                        (
                            "id",
                            models.AutoField(
                                auto_created=True,
                                primary_key=True,
                                serialize=False,
                                verbose_name="ID",
                            ),
                        ),
                        ("token", models.CharField(max_length=30)),
                        (
                            "email",
                            models.CharField(
                                blank=True, default=None, max_length=200, null=True
                            ),
                        ),
                        ("expiry", models.DateTimeField()),
                        ("verified", models.BooleanField(default=False)),
                        (
                            "user",
                            models.ForeignKey(
                                blank=True,
                                null=True,
                                on_delete=django.db.models.deletion.CASCADE,
                                related_name="email_verifications",
                                to=settings.AUTH_USER_MODEL,
                            ),
                        ),
                    ],
                )
            ],
            # Table already exists. See portal/migrations/0058_move_to_common_models.py
            database_operations=[],
        ),
    ]
