# Generated by Django 4.2.dev20221212103954 on 2022-12-12 11:01

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


class Migration(migrations.Migration):

    dependencies = [
        migrations.swappable_dependency(settings.AUTH_USER_MODEL),
        ("tests", "0013_draftstatemodel_add_lockablemixin"),
    ]

    operations = [
        migrations.CreateModel(
            name="LockableModel",
            fields=[
                (
                    "id",
                    models.AutoField(
                        auto_created=True,
                        primary_key=True,
                        serialize=False,
                        verbose_name="ID",
                    ),
                ),
                (
                    "locked",
                    models.BooleanField(
                        default=False, editable=False, verbose_name="locked"
                    ),
                ),
                (
                    "locked_at",
                    models.DateTimeField(
                        editable=False, null=True, verbose_name="locked at"
                    ),
                ),
                ("text", models.TextField()),
                (
                    "locked_by",
                    models.ForeignKey(
                        blank=True,
                        editable=False,
                        null=True,
                        on_delete=django.db.models.deletion.SET_NULL,
                        related_name="locked_%(class)ss",
                        to=settings.AUTH_USER_MODEL,
                        verbose_name="locked by",
                    ),
                ),
            ],
            options={
                "abstract": False,
            },
        ),
    ]
