# Generated by Django 3.2.23 on 2024-02-25 03:14

from django.db import migrations


class Migration(migrations.Migration):
    dependencies = [
        ("NEMO", "0061_alter_interlock_unique_together"),
    ]

    def migrate_customization_forward(apps, schema_editor):
        Customization = apps.get_model("NEMO", "Customization")
        qualified = Customization.objects.filter(name="tool_control_broadcast_upcoming_reservation").first()
        if qualified and qualified.value == "enabled":
            qualified.value = "qualified"
            qualified.save()

    def migrate_customization_reverse(apps, schema_editor):
        Customization = apps.get_model("NEMO", "Customization")
        qualified = Customization.objects.filter(name="tool_control_broadcast_upcoming_reservation").first()
        if qualified and qualified.value == "qualified":
            qualified.value = "enabled"
            qualified.save()

    operations = [
        migrations.RunPython(migrate_customization_forward, migrate_customization_reverse),
    ]
