# Generated by Django 4.2.11 on 2024-07-02 01:06

from django.db import migrations, models
import django.db.models.deletion
import edc_sites.managers
import edc_utils.date


class Migration(migrations.Migration):

    dependencies = [
        ("sites", "0002_alter_domain_unique"),
        (
            "intecomm_reports",
            "0004_remove_diagnoses_baseline_diagnoses_baseline_182d_and_more",
        ),
    ]

    operations = [
        migrations.CreateModel(
            name="Vl",
            fields=[
                (
                    "id",
                    models.BigAutoField(
                        auto_created=True, primary_key=True, serialize=False, verbose_name="ID"
                    ),
                ),
                ("subject_identifier", models.CharField(max_length=25)),
                (
                    "report_model",
                    models.CharField(default="intecomm_reports.vl", max_length=50),
                ),
                ("created", models.DateTimeField(default=edc_utils.date.get_utcnow)),
                ("baseline_date", models.DateField(null=True)),
                ("baseline_vl_date", models.DateField(null=True)),
                ("endline_vl_date", models.DateField(null=True)),
                ("baseline_vl", models.IntegerField(null=True)),
                ("endline_vl", models.IntegerField(null=True)),
            ],
            options={
                "verbose_name": "Viral load summary",
                "verbose_name_plural": "Viral load summary",
                "db_table": "intecomm_reports_vl_view",
                "managed": False,
            },
            managers=[
                ("on_site", edc_sites.managers.CurrentSiteManager()),
            ],
        ),
        migrations.CreateModel(
            name="VlSummary",
            fields=[
                (
                    "id",
                    models.BigAutoField(
                        auto_created=True, primary_key=True, serialize=False, verbose_name="ID"
                    ),
                ),
                ("subject_identifier", models.CharField(max_length=50, unique=True)),
                (
                    "report_model",
                    models.CharField(default="intecomm_reports.vlsummary", max_length=50),
                ),
                ("created", models.DateTimeField(default=edc_utils.date.get_utcnow)),
                ("baseline_date", models.DateField(null=True)),
                ("baseline_vl_date", models.DateField(null=True)),
                ("endline_vl_date", models.DateField(null=True)),
                ("baseline_vl", models.IntegerField(null=True)),
                ("endline_vl", models.IntegerField(null=True)),
                (
                    "site",
                    models.ForeignKey(
                        on_delete=django.db.models.deletion.PROTECT, to="sites.site"
                    ),
                ),
            ],
            options={
                "verbose_name": "Viral load summary",
                "verbose_name_plural": "Viral load summary",
            },
            managers=[
                ("on_site", edc_sites.managers.CurrentSiteManager()),
            ],
        ),
    ]
