From 3962e9ba81e46c27da2707cade1aa813440c5536 Mon Sep 17 00:00:00 2001 From: Johan Cwiklinski Date: Thu, 25 Apr 2024 22:28:36 +0200 Subject: [PATCH] Use constants --- galette/lib/Galette/Entity/Contribution.php | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/galette/lib/Galette/Entity/Contribution.php b/galette/lib/Galette/Entity/Contribution.php index 940b8c79d..39175b605 100644 --- a/galette/lib/Galette/Entity/Contribution.php +++ b/galette/lib/Galette/Entity/Contribution.php @@ -567,7 +567,7 @@ public function checkOverlap(): bool|string 'c.' . ContributionsTypes::PK . '=ct.' . ContributionsTypes::PK, array() )->where([Adherent::PK => $this->member]) - ->where->notEqualTo('cotis_extension', 0) + ->where->notEqualTo('cotis_extension', ContributionType::TYPE_DONATION) ->where->nest->nest ->greaterThanOrEqualTo('date_debut_cotis', $this->begin_date) ->lessThanOrEqualTo('date_debut_cotis', $this->end_date) @@ -865,7 +865,7 @@ public static function getDueDate(Db $zdb, ?int $member_id): ?string )->where( [Adherent::PK => $member_id] ) - ->where->notEqualTo('cotis_extension', 0); + ->where->notEqualTo('cotis_extension', ContributionType::TYPE_DONATION); $results = $zdb->execute($select); $result = $results->current();