diff --git a/internal/db/migrations/134_berufung_unification.down.sql b/internal/db/migrations/134_berufung_unification.down.sql index c26f6ed..04455fc 100644 --- a/internal/db/migrations/134_berufung_unification.down.sql +++ b/internal/db/migrations/134_berufung_unification.down.sql @@ -9,6 +9,16 @@ -- never deleted them — that's what makes this down-migration safe). -- --------------------------------------------------------------- +-- --------------------------------------------------------------- +-- 0. Audit reason (required by mig 079 trigger — step 2 UPDATEs +-- paliad.deadline_rules to reverse the reassignment). +-- --------------------------------------------------------------- + +SELECT set_config( + 'paliad.audit_reason', + 'mig 134 DOWN: revert Slice B1 — restore 3 separate UPC appeal proceeding_types, drop applies_to_target column', + true); + -- --------------------------------------------------------------- -- 1. Un-archive the 3 old appeal proceeding_types. -- --------------------------------------------------------------- diff --git a/internal/db/migrations/134_berufung_unification.up.sql b/internal/db/migrations/134_berufung_unification.up.sql index b7024fb..4df2e52 100644 --- a/internal/db/migrations/134_berufung_unification.up.sql +++ b/internal/db/migrations/134_berufung_unification.up.sql @@ -25,6 +25,16 @@ -- -- See docs/design-litigation-planner-2026-05-26.md §18.1. +-- --------------------------------------------------------------- +-- 0. Audit reason (required by mig 079 trigger for any UPDATE on +-- paliad.deadline_rules — step 4 reassigns 16 rules). +-- --------------------------------------------------------------- + +SELECT set_config( + 'paliad.audit_reason', + 'mig 134: t-paliad-292 Slice B1 — Berufung unification, collapse 3 UPC appeal proceeding_types into upc.apl.unified + appeal_target discriminator', + true); + -- --------------------------------------------------------------- -- 1. Schema additions -- ---------------------------------------------------------------