details: https://code.tryton.org/tryton/commit/d4c4995588f3
branch: default
user: Cédric Krier <[email protected]>
date: Thu Apr 02 15:33:36 2026 +0200
description:
Do not match direct debit reception with SEPA mandate that is not
validated
Closes #14738
diffstat:
modules/account_payment_sepa/party.py | 7 +++++++
1 files changed, 7 insertions(+), 0 deletions(-)
diffs (17 lines):
diff -r 89e59ce6f450 -r d4c4995588f3 modules/account_payment_sepa/party.py
--- a/modules/account_payment_sepa/party.py Thu Apr 02 10:26:27 2026 +0200
+++ b/modules/account_payment_sepa/party.py Thu Apr 02 15:33:36 2026 +0200
@@ -68,6 +68,13 @@
payment.sepa_mandate = self.sepa_mandate
return payment
+ def match(self, pattern, match_none=False):
+ result = super().match(pattern, match_none=match_none)
+ if (self.process_method == 'sepa'
+ and self.sepa_mandate.state != 'validated'):
+ result = False
+ return result
+
class PartyIdentifier(metaclass=PoolMeta):
__name__ = 'party.identifier'