# Generated by Django 4.2.5 on 2023-10-16 09:41

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


class Migration(migrations.Migration):
    initial = True

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

    operations = [
        migrations.CreateModel(
            name="VCTemplate",
            fields=[
                (
                    "id",
                    models.BigAutoField(
                        auto_created=True,
                        primary_key=True,
                        serialize=False,
                        verbose_name="ID",
                    ),
                ),
                ("wkit_template_id", models.CharField(max_length=250)),
                ("data", models.TextField()),
            ],
        ),
        migrations.CreateModel(
            name="VerifiableCredential",
            fields=[
                (
                    "id",
                    models.BigAutoField(
                        auto_created=True,
                        primary_key=True,
                        serialize=False,
                        verbose_name="ID",
                    ),
                ),
                ("id_string", models.CharField(max_length=250)),
                ("verified", models.BooleanField()),
                ("created_on", models.DateTimeField()),
                ("did_issuer", models.CharField(max_length=250)),
                ("did_subject", models.CharField(max_length=250)),
                ("data", models.TextField()),
                (
                    "user",
                    models.ForeignKey(
                        on_delete=django.db.models.deletion.CASCADE,
                        related_name="vcredentials",
                        to=settings.AUTH_USER_MODEL,
                    ),
                ),
            ],
        ),
        migrations.CreateModel(
            name="Membership",
            fields=[
                (
                    "id",
                    models.BigAutoField(
                        auto_created=True,
                        primary_key=True,
                        serialize=False,
                        verbose_name="ID",
                    ),
                ),
                (
                    "type",
                    models.PositiveSmallIntegerField(
                        choices=[(1, "Beneficiary"), (2, "Employee"), (3, "Partner")],
                        verbose_name="Type of membership",
                    ),
                ),
                (
                    "start_date",
                    models.DateField(
                        blank=True,
                        help_text="What date did the membership start?",
                        null=True,
                        verbose_name="Start date",
                    ),
                ),
                (
                    "end_date",
                    models.DateField(
                        blank=True,
                        help_text="What date did the membership end?",
                        null=True,
                        verbose_name="End date",
                    ),
                ),
                (
                    "user",
                    models.ForeignKey(
                        on_delete=django.db.models.deletion.CASCADE,
                        related_name="memberships",
                        to=settings.AUTH_USER_MODEL,
                    ),
                ),
            ],
        ),
        migrations.CreateModel(
            name="DID",
            fields=[
                (
                    "id",
                    models.BigAutoField(
                        auto_created=True,
                        primary_key=True,
                        serialize=False,
                        verbose_name="ID",
                    ),
                ),
                ("did_string", models.CharField(max_length=250)),
                ("label", models.CharField(max_length=50)),
                (
                    "user",
                    models.ForeignKey(
                        on_delete=django.db.models.deletion.CASCADE,
                        related_name="dids",
                        to=settings.AUTH_USER_MODEL,
                    ),
                ),
            ],
        ),
    ]
