# Generated by Django 3.2.16 on 2022-12-24 02:54

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


class Migration(migrations.Migration):

    initial = True

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

    operations = [
        migrations.CreateModel(
            name="Ethnicity",
            fields=[
                ("id", models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name="ID")),
                ("name", models.CharField(help_text="The name of the ethnicity", max_length=200, unique=True)),
            ],
            options={
                "verbose_name_plural": "Ethnicities",
                "ordering": ["name"],
            },
        ),
        migrations.CreateModel(
            name="Gender",
            fields=[
                ("id", models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name="ID")),
                ("name", models.CharField(help_text="The name of the gender", max_length=200, unique=True)),
            ],
            options={
                "ordering": ["name"],
            },
        ),
        migrations.CreateModel(
            name="Race",
            fields=[
                ("id", models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name="ID")),
                ("name", models.CharField(help_text="The name of the race", max_length=200, unique=True)),
            ],
            options={
                "ordering": ["name"],
            },
        ),
        migrations.CreateModel(
            name="UserDetails",
            fields=[
                ("id", models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name="ID")),
                (
                    "emergency_contact",
                    models.CharField(blank=True, max_length=250, help_text="The user's emergency contact information"),
                ),
                ("phone_number", models.CharField(blank=True, max_length=40, help_text="The user's phone number")),
                (
                    "ethnicity",
                    models.ForeignKey(
                        blank=True,
                        help_text="The user's ethnicity",
                        null=True,
                        on_delete=django.db.models.deletion.SET_NULL,
                        to="NEMO_user_details.ethnicity",
                    ),
                ),
                (
                    "gender",
                    models.ForeignKey(
                        blank=True,
                        help_text="The user's gender",
                        null=True,
                        on_delete=django.db.models.deletion.SET_NULL,
                        to="NEMO_user_details.gender",
                    ),
                ),
                (
                    "race",
                    models.ForeignKey(
                        blank=True,
                        help_text="The user's race",
                        null=True,
                        on_delete=django.db.models.deletion.SET_NULL,
                        to="NEMO_user_details.race",
                    ),
                ),
                (
                    "user",
                    models.OneToOneField(
                        on_delete=django.db.models.deletion.CASCADE, related_name="details", to=settings.AUTH_USER_MODEL
                    ),
                ),
            ],
            options={
                "abstract": False,
            },
        ),
    ]
