# Generated by Django 5.2.9 on 2026-01-08 18:05

import pgtrigger.compiler
import pgtrigger.migrations
from django.db import migrations, models


class Migration(migrations.Migration):

    dependencies = [
        ('rides', '0036_add_remaining_parity_fields'),
    ]

    operations = [
        pgtrigger.migrations.RemoveTrigger(
            model_name='ride',
            name='insert_insert',
        ),
        pgtrigger.migrations.RemoveTrigger(
            model_name='ride',
            name='update_update',
        ),
        pgtrigger.migrations.RemoveTrigger(
            model_name='ridemodel',
            name='insert_insert',
        ),
        pgtrigger.migrations.RemoveTrigger(
            model_name='ridemodel',
            name='update_update',
        ),
        migrations.AddField(
            model_name='ride',
            name='is_test_data',
            field=models.BooleanField(default=False, help_text='Whether this is test/development data'),
        ),
        migrations.AddField(
            model_name='ride',
            name='source_url',
            field=models.URLField(blank=True, help_text='Source URL for the data (e.g., official website, RCDB)'),
        ),
        migrations.AddField(
            model_name='rideevent',
            name='is_test_data',
            field=models.BooleanField(default=False, help_text='Whether this is test/development data'),
        ),
        migrations.AddField(
            model_name='rideevent',
            name='source_url',
            field=models.URLField(blank=True, help_text='Source URL for the data (e.g., official website, RCDB)'),
        ),
        migrations.AddField(
            model_name='ridemodel',
            name='is_test_data',
            field=models.BooleanField(default=False, help_text='Whether this is test/development data'),
        ),
        migrations.AddField(
            model_name='ridemodel',
            name='source_url',
            field=models.URLField(blank=True, help_text='Source URL for the data (e.g., manufacturer website)'),
        ),
        migrations.AddField(
            model_name='ridemodelevent',
            name='is_test_data',
            field=models.BooleanField(default=False, help_text='Whether this is test/development data'),
        ),
        migrations.AddField(
            model_name='ridemodelevent',
            name='source_url',
            field=models.URLField(blank=True, help_text='Source URL for the data (e.g., manufacturer website)'),
        ),
        migrations.AlterField(
            model_name='ride',
            name='closing_date_precision',
            field=models.CharField(blank=True, choices=[('exact', 'Exact Date'), ('month', 'Month and Year'), ('year', 'Year Only'), ('decade', 'Decade'), ('century', 'Century'), ('approximate', 'Approximate')], default='exact', help_text='Precision of the closing date', max_length=20),
        ),
        migrations.AlterField(
            model_name='ride',
            name='opening_date_precision',
            field=models.CharField(blank=True, choices=[('exact', 'Exact Date'), ('month', 'Month and Year'), ('year', 'Year Only'), ('decade', 'Decade'), ('century', 'Century'), ('approximate', 'Approximate')], default='exact', help_text='Precision of the opening date', max_length=20),
        ),
        migrations.AlterField(
            model_name='rideevent',
            name='closing_date_precision',
            field=models.CharField(blank=True, choices=[('exact', 'Exact Date'), ('month', 'Month and Year'), ('year', 'Year Only'), ('decade', 'Decade'), ('century', 'Century'), ('approximate', 'Approximate')], default='exact', help_text='Precision of the closing date', max_length=20),
        ),
        migrations.AlterField(
            model_name='rideevent',
            name='opening_date_precision',
            field=models.CharField(blank=True, choices=[('exact', 'Exact Date'), ('month', 'Month and Year'), ('year', 'Year Only'), ('decade', 'Decade'), ('century', 'Century'), ('approximate', 'Approximate')], default='exact', help_text='Precision of the opening date', max_length=20),
        ),
        pgtrigger.migrations.AddTrigger(
            model_name='ride',
            trigger=pgtrigger.compiler.Trigger(name='insert_insert', sql=pgtrigger.compiler.UpsertTriggerSql(func='INSERT INTO "rides_rideevent" ("age_requirement", "animatronics_count", "arm_length_meters", "average_rating", "banner_image_id", "boat_capacity", "capacity_per_hour", "card_image_id", "category", "character_theme", "closing_date", "closing_date_precision", "coaster_type", "created_at", "description", "designer_id", "drop_meters", "duration_seconds", "educational_theme", "flume_type", "gforce_max", "height_meters", "height_requirement_cm", "id", "intensity_level", "inversions_count", "is_test_data", "length_meters", "manufacturer_id", "max_age", "max_height_in", "max_height_reached_meters", "max_speed_kmh", "min_age", "min_height_in", "motion_pattern", "name", "opening_date", "opening_date_precision", "opening_year", "park_area_id", "park_id", "park_url", "pgh_context_id", "pgh_created_at", "pgh_label", "pgh_obj_id", "platform_count", "post_closing_status", "projection_type", "propulsion_method", "ride_duration_seconds", "ride_model_id", "ride_sub_type", "ride_system", "rotation_speed_rpm", "rotation_type", "round_trip_duration_seconds", "route_length_meters", "scenes_count", "search_text", "seating_type", "show_duration_seconds", "slug", "source_url", "splash_height_meters", "stations_count", "status", "status_since", "story_description", "support_material", "swing_angle_degrees", "theme_name", "track_material", "transport_type", "updated_at", "url", "vehicle_capacity", "vehicles_count", "water_depth_cm", "wetness_level") VALUES (NEW."age_requirement", NEW."animatronics_count", NEW."arm_length_meters", NEW."average_rating", NEW."banner_image_id", NEW."boat_capacity", NEW."capacity_per_hour", NEW."card_image_id", NEW."category", NEW."character_theme", NEW."closing_date", NEW."closing_date_precision", NEW."coaster_type", NEW."created_at", NEW."description", NEW."designer_id", NEW."drop_meters", NEW."duration_seconds", NEW."educational_theme", NEW."flume_type", NEW."gforce_max", NEW."height_meters", NEW."height_requirement_cm", NEW."id", NEW."intensity_level", NEW."inversions_count", NEW."is_test_data", NEW."length_meters", NEW."manufacturer_id", NEW."max_age", NEW."max_height_in", NEW."max_height_reached_meters", NEW."max_speed_kmh", NEW."min_age", NEW."min_height_in", NEW."motion_pattern", NEW."name", NEW."opening_date", NEW."opening_date_precision", NEW."opening_year", NEW."park_area_id", NEW."park_id", NEW."park_url", _pgh_attach_context(), NOW(), \'insert\', NEW."id", NEW."platform_count", NEW."post_closing_status", NEW."projection_type", NEW."propulsion_method", NEW."ride_duration_seconds", NEW."ride_model_id", NEW."ride_sub_type", NEW."ride_system", NEW."rotation_speed_rpm", NEW."rotation_type", NEW."round_trip_duration_seconds", NEW."route_length_meters", NEW."scenes_count", NEW."search_text", NEW."seating_type", NEW."show_duration_seconds", NEW."slug", NEW."source_url", NEW."splash_height_meters", NEW."stations_count", NEW."status", NEW."status_since", NEW."story_description", NEW."support_material", NEW."swing_angle_degrees", NEW."theme_name", NEW."track_material", NEW."transport_type", NEW."updated_at", NEW."url", NEW."vehicle_capacity", NEW."vehicles_count", NEW."water_depth_cm", NEW."wetness_level"); RETURN NULL;', hash='07c5cf95d16c49e08014c23a4e5e35f55292c869', operation='INSERT', pgid='pgtrigger_insert_insert_52074', table='rides_ride', when='AFTER')),
        ),
        pgtrigger.migrations.AddTrigger(
            model_name='ride',
            trigger=pgtrigger.compiler.Trigger(name='update_update', sql=pgtrigger.compiler.UpsertTriggerSql(condition='WHEN (OLD.* IS DISTINCT FROM NEW.*)', func='INSERT INTO "rides_rideevent" ("age_requirement", "animatronics_count", "arm_length_meters", "average_rating", "banner_image_id", "boat_capacity", "capacity_per_hour", "card_image_id", "category", "character_theme", "closing_date", "closing_date_precision", "coaster_type", "created_at", "description", "designer_id", "drop_meters", "duration_seconds", "educational_theme", "flume_type", "gforce_max", "height_meters", "height_requirement_cm", "id", "intensity_level", "inversions_count", "is_test_data", "length_meters", "manufacturer_id", "max_age", "max_height_in", "max_height_reached_meters", "max_speed_kmh", "min_age", "min_height_in", "motion_pattern", "name", "opening_date", "opening_date_precision", "opening_year", "park_area_id", "park_id", "park_url", "pgh_context_id", "pgh_created_at", "pgh_label", "pgh_obj_id", "platform_count", "post_closing_status", "projection_type", "propulsion_method", "ride_duration_seconds", "ride_model_id", "ride_sub_type", "ride_system", "rotation_speed_rpm", "rotation_type", "round_trip_duration_seconds", "route_length_meters", "scenes_count", "search_text", "seating_type", "show_duration_seconds", "slug", "source_url", "splash_height_meters", "stations_count", "status", "status_since", "story_description", "support_material", "swing_angle_degrees", "theme_name", "track_material", "transport_type", "updated_at", "url", "vehicle_capacity", "vehicles_count", "water_depth_cm", "wetness_level") VALUES (NEW."age_requirement", NEW."animatronics_count", NEW."arm_length_meters", NEW."average_rating", NEW."banner_image_id", NEW."boat_capacity", NEW."capacity_per_hour", NEW."card_image_id", NEW."category", NEW."character_theme", NEW."closing_date", NEW."closing_date_precision", NEW."coaster_type", NEW."created_at", NEW."description", NEW."designer_id", NEW."drop_meters", NEW."duration_seconds", NEW."educational_theme", NEW."flume_type", NEW."gforce_max", NEW."height_meters", NEW."height_requirement_cm", NEW."id", NEW."intensity_level", NEW."inversions_count", NEW."is_test_data", NEW."length_meters", NEW."manufacturer_id", NEW."max_age", NEW."max_height_in", NEW."max_height_reached_meters", NEW."max_speed_kmh", NEW."min_age", NEW."min_height_in", NEW."motion_pattern", NEW."name", NEW."opening_date", NEW."opening_date_precision", NEW."opening_year", NEW."park_area_id", NEW."park_id", NEW."park_url", _pgh_attach_context(), NOW(), \'update\', NEW."id", NEW."platform_count", NEW."post_closing_status", NEW."projection_type", NEW."propulsion_method", NEW."ride_duration_seconds", NEW."ride_model_id", NEW."ride_sub_type", NEW."ride_system", NEW."rotation_speed_rpm", NEW."rotation_type", NEW."round_trip_duration_seconds", NEW."route_length_meters", NEW."scenes_count", NEW."search_text", NEW."seating_type", NEW."show_duration_seconds", NEW."slug", NEW."source_url", NEW."splash_height_meters", NEW."stations_count", NEW."status", NEW."status_since", NEW."story_description", NEW."support_material", NEW."swing_angle_degrees", NEW."theme_name", NEW."track_material", NEW."transport_type", NEW."updated_at", NEW."url", NEW."vehicle_capacity", NEW."vehicles_count", NEW."water_depth_cm", NEW."wetness_level"); RETURN NULL;', hash='dabf771ba40b71c4d91ad1b1ed97a9712578096c', operation='UPDATE', pgid='pgtrigger_update_update_4917a', table='rides_ride', when='AFTER')),
        ),
        pgtrigger.migrations.AddTrigger(
            model_name='ridemodel',
            trigger=pgtrigger.compiler.Trigger(name='insert_insert', sql=pgtrigger.compiler.UpsertTriggerSql(func='INSERT INTO "rides_ridemodelevent" ("category", "created_at", "description", "first_installation_year", "id", "is_discontinued", "is_test_data", "last_installation_year", "manufacturer_id", "meta_description", "meta_title", "name", "notable_features", "pgh_context_id", "pgh_created_at", "pgh_label", "pgh_obj_id", "primary_image_id", "restraint_system", "ride_type", "slug", "source_url", "support_structure", "target_market", "total_installations", "track_type", "train_configuration", "typical_capacity_range_max", "typical_capacity_range_min", "typical_height_range_max_ft", "typical_height_range_min_ft", "typical_speed_range_max_mph", "typical_speed_range_min_mph", "updated_at", "url") VALUES (NEW."category", NEW."created_at", NEW."description", NEW."first_installation_year", NEW."id", NEW."is_discontinued", NEW."is_test_data", NEW."last_installation_year", NEW."manufacturer_id", NEW."meta_description", NEW."meta_title", NEW."name", NEW."notable_features", _pgh_attach_context(), NOW(), \'insert\', NEW."id", NEW."primary_image_id", NEW."restraint_system", NEW."ride_type", NEW."slug", NEW."source_url", NEW."support_structure", NEW."target_market", NEW."total_installations", NEW."track_type", NEW."train_configuration", NEW."typical_capacity_range_max", NEW."typical_capacity_range_min", NEW."typical_height_range_max_ft", NEW."typical_height_range_min_ft", NEW."typical_speed_range_max_mph", NEW."typical_speed_range_min_mph", NEW."updated_at", NEW."url"); RETURN NULL;', hash='9cc07f0217f79924bae066b5b8f9e7d5f55e211c', operation='INSERT', pgid='pgtrigger_insert_insert_0aaee', table='rides_ridemodel', when='AFTER')),
        ),
        pgtrigger.migrations.AddTrigger(
            model_name='ridemodel',
            trigger=pgtrigger.compiler.Trigger(name='update_update', sql=pgtrigger.compiler.UpsertTriggerSql(condition='WHEN (OLD.* IS DISTINCT FROM NEW.*)', func='INSERT INTO "rides_ridemodelevent" ("category", "created_at", "description", "first_installation_year", "id", "is_discontinued", "is_test_data", "last_installation_year", "manufacturer_id", "meta_description", "meta_title", "name", "notable_features", "pgh_context_id", "pgh_created_at", "pgh_label", "pgh_obj_id", "primary_image_id", "restraint_system", "ride_type", "slug", "source_url", "support_structure", "target_market", "total_installations", "track_type", "train_configuration", "typical_capacity_range_max", "typical_capacity_range_min", "typical_height_range_max_ft", "typical_height_range_min_ft", "typical_speed_range_max_mph", "typical_speed_range_min_mph", "updated_at", "url") VALUES (NEW."category", NEW."created_at", NEW."description", NEW."first_installation_year", NEW."id", NEW."is_discontinued", NEW."is_test_data", NEW."last_installation_year", NEW."manufacturer_id", NEW."meta_description", NEW."meta_title", NEW."name", NEW."notable_features", _pgh_attach_context(), NOW(), \'update\', NEW."id", NEW."primary_image_id", NEW."restraint_system", NEW."ride_type", NEW."slug", NEW."source_url", NEW."support_structure", NEW."target_market", NEW."total_installations", NEW."track_type", NEW."train_configuration", NEW."typical_capacity_range_max", NEW."typical_capacity_range_min", NEW."typical_height_range_max_ft", NEW."typical_height_range_min_ft", NEW."typical_speed_range_max_mph", NEW."typical_speed_range_min_mph", NEW."updated_at", NEW."url"); RETURN NULL;', hash='f9f826a678fc0ed93ab788206fdb724c5445e469', operation='UPDATE', pgid='pgtrigger_update_update_0ca1a', table='rides_ridemodel', when='AFTER')),
        ),
    ]
