PR-6 of the Unified Fristenrechner. Fills the EPA-side coverage gaps
named in the design + repairs three pre-existing EPA bugs surfaced
during this work.
Migration 045:
PRE-EXISTING BUG FIXES
1. EPA anchor convention bug. epa_opp.grant and epa_app.entsch were
seeded with party='court' + event_type='decision' → calculator's
isCourtDeterminedRule(r) returned true → those anchor rows
rendered as IsCourtSet (no date), propagating IsCourtSet to every
downstream rule that chained off them. Result on prod: EPA_OPP
showed "court-set" for Einspruchsfrist / Erwiderung / Entscheidung
instead of computed dates; ONLY the trailing beschwerde + begr
rendered dates (and only by accident, because they had parent_id=
NULL and computed off triggerDate directly).
Fix: changed both anchors to party='both' + event_type='filing' so
they render as IsRootEvent. Matches the convention I established
for DE_INF_OLG / DE_INF_BGH / DE_NULL_BGH / DPMA_BPATG_BESCHWERDE /
DPMA_BGH_RB anchors in PR-3/4/5.
2. EPA_OPP appeal-phase parent bug. epa_opp.beschwerde +
beschwerde_begr had parent_id=NULL → were computing 2mo and 4mo
from the GRANT date instead of from the OPPOSITION DECISION date.
Re-parented both on epa_opp.entsch. They now correctly render as
IsCourtSet placeholders (because entsch is court-set) until the
user enters the real decision date via the Phase A click-to-edit
affordance.
3. EPA_APP.erwidg modelling bug. Was parent_id=NULL + duration=0 +
party=both + event=filing → IsRootEvent → emitted the trigger date
as "Erwiderung". Now properly modelled per Art. 12(1)(c) RPBA 2020:
parent=epa_app.begr, duration=4 months, name="Beschwerdeerwiderung",
legal_source=EU.RPBA.12.1.c, response-to-appeal concept.
NEW COVERAGE (per design §5.3)
EPA_OPP gains 2 rules:
- epa_opp.r79_further: Stellungnahme weiterer Beteiligter
(R.79(2)/(3) EPC) — court-set, parent=erwidg
- epa_opp.r116: Eingaben vor mündl. Verhandlung
(R.116(1) EPC) — court-set, parent=entsch (so it surfaces in the
opposition phase but stays IsCourtSet until oral hearing date is
entered via override)
EPA_APP gains 2 rules:
- epa_app.r116: Eingaben vor mündl. Verhandlung
(R.116(1) EPC + Art. 13 RPBA) — court-set, parent=oral
- epa_app.r106: Antrag auf Überprüfung
(Art. 112a EPÜ) — 2 months from service of decision, parent=
entsch2 (the BoA decision)
Three new EN-slug concepts (UPC/EPC-native): r79-further-stellungnahme,
r116-final-submissions, petition-for-review.
Live-verified on paliad.de:
EPA_OPP trigger 2026-05-04 → grant IsRootEvent / Einspruchsfrist
2027-02-04 (9mo) / Erwiderung 2027-06-04 (4mo from frist) /
r79_further 2027-06-04 (filed-with-erwidg) / Entscheidung +
Beschwerde + Begründung + r116 IsCourtSet (waiting for entsch).
EPA_APP trigger 2026-05-04 → entsch IsRootEvent / Beschwerde
2026-07-06 (2mo, weekend-shift) / Begründung 2026-09-04 (4mo from
entsch) / Beschwerdeerwiderung 2027-01-04 (4mo from Begründung
per RPBA 12.1.c) / r116 IsCourtSet (parent=oral) / r106 IsCourtSet
(parent=entsch2, will compute 2mo from BoA decision once entered).
Out of scope (deferred to PR-7 cross-cutting): Wiedereinsetzung
(Art. 122 EPÜ + R.136 EPC), Weiterbehandlung (Art. 121 EPÜ + R.135 EPC),
Validierungsfrist national (Art. 65 EPÜ).
54 lines
2.1 KiB
SQL
54 lines
2.1 KiB
SQL
-- Reverses 045_epa_gap_fill.
|
|
|
|
DELETE FROM paliad.deadline_rules
|
|
WHERE proceeding_type_id IN (
|
|
SELECT id FROM paliad.proceeding_types WHERE code IN ('EPA_OPP','EPA_APP')
|
|
)
|
|
AND code IN ('epa_opp.r79_further','epa_opp.r116','epa_app.r116','epa_app.r106');
|
|
|
|
-- Restore epa_app.erwidg to its pre-fix shape.
|
|
UPDATE paliad.deadline_rules
|
|
SET name = 'Erwiderung',
|
|
name_en = 'Response',
|
|
parent_id = NULL,
|
|
duration_value = 0,
|
|
duration_unit = 'months',
|
|
primary_party = 'both',
|
|
event_type = 'filing',
|
|
rule_code = NULL,
|
|
legal_source = NULL,
|
|
deadline_notes = NULL,
|
|
deadline_notes_en = NULL,
|
|
concept_id = NULL
|
|
WHERE proceeding_type_id = (SELECT id FROM paliad.proceeding_types WHERE code = 'EPA_APP')
|
|
AND code = 'epa_app.erwidg';
|
|
|
|
-- Restore epa_opp.beschwerde + beschwerde_begr to parent_id=NULL.
|
|
UPDATE paliad.deadline_rules
|
|
SET parent_id = NULL
|
|
WHERE proceeding_type_id = (SELECT id FROM paliad.proceeding_types WHERE code = 'EPA_OPP')
|
|
AND code IN ('epa_opp.beschwerde', 'epa_opp.beschwerde_begr');
|
|
|
|
-- Restore anchor party/event_type.
|
|
UPDATE paliad.deadline_rules
|
|
SET primary_party = 'court',
|
|
event_type = 'decision',
|
|
deadline_notes = NULL,
|
|
deadline_notes_en = NULL
|
|
WHERE proceeding_type_id = (SELECT id FROM paliad.proceeding_types WHERE code = 'EPA_OPP')
|
|
AND code = 'epa_opp.grant';
|
|
|
|
UPDATE paliad.deadline_rules
|
|
SET primary_party = 'court',
|
|
event_type = 'decision',
|
|
name = 'Zustellung der Entscheidung',
|
|
name_en = 'Notification of Decision',
|
|
deadline_notes = NULL,
|
|
deadline_notes_en = NULL
|
|
WHERE proceeding_type_id = (SELECT id FROM paliad.proceeding_types WHERE code = 'EPA_APP')
|
|
AND code = 'epa_app.entsch';
|
|
|
|
DELETE FROM paliad.deadline_concepts
|
|
WHERE slug IN ('r79-further-stellungnahme','r116-final-submissions','petition-for-review')
|
|
AND id NOT IN (SELECT concept_id FROM paliad.deadline_rules WHERE concept_id IS NOT NULL);
|