# Generated by Django 5.1.15 on 2026-02-09 03:45

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


class Migration(migrations.Migration):

    dependencies = [
        ("itim", "0014_alter_cluster_organization_and_more"),
    ]

    operations = [
        migrations.CreateModel(
            name="ChangeTicket",
            fields=[
                (
                    "slmticket_ptr",
                    models.OneToOneField(
                        auto_created=True,
                        on_delete=django.db.models.deletion.CASCADE,
                        parent_link=True,
                        primary_key=True,
                        serialize=False,
                        to="itim.slmticket",
                    ),
                ),
            ],
            options={
                "verbose_name": "Change",
                "verbose_name_plural": "Changes",
                "ordering": ["id"],
                "permissions": [
                    ("import_changeticket", "Can import change ticket"),
                    ("purge_changeticket", "Can purge change ticket"),
                    ("triage_changeticket", "Can triage change ticket"),
                ],
                "sub_model_type": "change",
            },
            bases=("itim.slmticket",),
        ),
        migrations.CreateModel(
            name="IncidentTicket",
            fields=[
                (
                    "slmticket_ptr",
                    models.OneToOneField(
                        auto_created=True,
                        on_delete=django.db.models.deletion.CASCADE,
                        parent_link=True,
                        primary_key=True,
                        serialize=False,
                        to="itim.slmticket",
                    ),
                ),
            ],
            options={
                "verbose_name": "Incident",
                "verbose_name_plural": "Incidents",
                "ordering": ["id"],
                "permissions": [
                    ("import_incidentticket", "Can import incident ticket"),
                    ("purge_incidentticket", "Can purge incident ticket"),
                    ("triage_incidentticket", "Can triage incident ticket"),
                ],
                "sub_model_type": "incident",
            },
            bases=("itim.slmticket",),
        ),
        migrations.CreateModel(
            name="ProblemTicket",
            fields=[
                (
                    "slmticket_ptr",
                    models.OneToOneField(
                        auto_created=True,
                        on_delete=django.db.models.deletion.CASCADE,
                        parent_link=True,
                        primary_key=True,
                        serialize=False,
                        to="itim.slmticket",
                    ),
                ),
                (
                    "business_impact",
                    models.TextField(
                        blank=True,
                        help_text="Description of the impact to operations.",
                        null=True,
                        verbose_name="Business Impact",
                    ),
                ),
                (
                    "cause_analysis",
                    models.TextField(
                        blank=True,
                        help_text="Detailed technical analysis identifying root cause.",
                        null=True,
                        verbose_name="Root Cause Analysis (RCA)",
                    ),
                ),
                (
                    "observations",
                    models.TextField(
                        blank=True,
                        help_text="Summary of known symptoms or evidence.",
                        null=True,
                        verbose_name="Observation(s)",
                    ),
                ),
                (
                    "workaround",
                    models.TextField(
                        blank=True,
                        help_text="Temporary fix allowing service continuation.",
                        null=True,
                        verbose_name="Workaround(s)",
                    ),
                ),
            ],
            options={
                "verbose_name": "Problem",
                "verbose_name_plural": "Problems",
                "ordering": ["id"],
                "permissions": [
                    ("import_problemticket", "Can import problem ticket"),
                    ("purge_problemticket", "Can purge problem ticket"),
                    ("triage_problemticket", "Can triage problem ticket"),
                ],
                "sub_model_type": "problem",
            },
            bases=("itim.slmticket",),
        ),
        migrations.DeleteModel(
            name="ClusterHistory",
        ),
        migrations.DeleteModel(
            name="ClusterNotes",
        ),
        migrations.DeleteModel(
            name="ClusterTypeHistory",
        ),
        migrations.DeleteModel(
            name="ClusterTypeNotes",
        ),
        migrations.DeleteModel(
            name="PortHistory",
        ),
        migrations.DeleteModel(
            name="PortNotes",
        ),
        migrations.DeleteModel(
            name="ServiceHistory",
        ),
        migrations.DeleteModel(
            name="ServiceNotes",
        ),
    ]
