diff --git a/galette/lib/Galette/Entity/Contribution.php b/galette/lib/Galette/Entity/Contribution.php index 940b8c79d..aa9c1ce41 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', ContributionsTypes::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', ContributionsTypes::TYPE_DONATION); $results = $zdb->execute($select); $result = $results->current();