Update SEPA mandate on party replace

issue10553
review358871002
This commit is contained in:
David Blanco Bautista committed 2021-09-10 19:33:26 +02:00
1 parent b8a2147089
commit fdd1a160dd
2 files changed
+13

No files matched your search

+3
View File
@@ -18,6 +18,9 @@ def register():
account.Configuration,
account.ConfigurationSepaMandateSequence,
module='account_payment_sepa', type_='model')
Pool.register(
party.Replace,
module='account_payment_sepa', type_='wizard')
Pool.register(
payment.MandateReport,
module='account_payment_sepa', type_='report')
+10
View File
@@ -108,3 +108,13 @@ class PartyIdentifier(metaclass=PoolMeta):
elif self.type == 'es_nif':
identifier['Id'] += self.sepa_es_suffix or '000'
return identifier
class Replace(metaclass=PoolMeta):
__name__ = 'party.replace'
@classmethod
def fields_to_replace(cls):
return super().fields_to_replace() + [
('account.payment.sepa.mandate', 'party'),
]