diff --git a/account_ebics/__manifest__.py b/account_ebics/__manifest__.py index 16791e1..65003c0 100644 --- a/account_ebics/__manifest__.py +++ b/account_ebics/__manifest__.py @@ -3,7 +3,7 @@ { "name": "EBICS banking protocol", - "version": "16.0.1.6.0", + "version": "16.0.1.6.1", "license": "LGPL-3", "author": "Noviat", "website": "https://www.noviat.com/", diff --git a/account_ebics/models/ebics_file.py b/account_ebics/models/ebics_file.py index 7ef3514..f27faa3 100644 --- a/account_ebics/models/ebics_file.py +++ b/account_ebics/models/ebics_file.py @@ -550,6 +550,11 @@ class EbicsFile(models.Model): currency_code = stmt.xpath( "ns:Acct/ns:Ccy/text() | ns:Bal/ns:Amt/@Ccy", namespaces=ns )[0] + # some banks (e.g. COMMERZBANK) add the currency as the last 3 digits + # of the bank account number hence we need to remove this since otherwise + # the journal matching logic fails + if acc_number[-3:] == currency_code: + acc_number = acc_number[:-3] root_new = deepcopy(root) entries = False