From 17de730c53e5bdc3777f6464b3f5df8c27542c8a Mon Sep 17 00:00:00 2001 From: mpeltriaux Date: Thu, 26 Oct 2023 07:26:38 +0200 Subject: [PATCH] HOTFIX * corrects behaviour of lanis link generation for EIV and KOM --- compensation/models/compensation.py | 2 +- intervention/models/intervention.py | 3 ++- 2 files changed, 3 insertions(+), 2 deletions(-) diff --git a/compensation/models/compensation.py b/compensation/models/compensation.py index f3fd0a9f..86956b42 100644 --- a/compensation/models/compensation.py +++ b/compensation/models/compensation.py @@ -493,7 +493,7 @@ class Compensation(AbstractCompensation, CEFMixin, CoherenceMixin, PikMixin): try: is_old_entry = self.intervention.legal.binding_date < LKOMPVZVO_PUBLISH_DATE except TypeError: - is_old_entry = True + is_old_entry = False if is_old_entry: retval = COMPENSATION_LANIS_LAYER_NAME_UNRECORDED_OLD_ENTRY diff --git a/intervention/models/intervention.py b/intervention/models/intervention.py index 25779c30..e6077694 100644 --- a/intervention/models/intervention.py +++ b/intervention/models/intervention.py @@ -398,7 +398,8 @@ class Intervention(BaseObject, try: is_old_entry = self.legal.binding_date < LKOMPVZVO_PUBLISH_DATE except TypeError: - is_old_entry = True + is_old_entry = False + if is_old_entry: retval = INTERVENTION_LANIS_LAYER_NAME_UNRECORDED_OLD_ENTRY else: