From b48ca01e705f9e9ae3b32f4d6e8d1517136362c5 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?C=C3=A9dric=20Krier?= Date: Tue, 8 Oct 2019 18:24:45 +0200 Subject: [PATCH] Add initiator id on journal Each country/bank has its own requirement about the ID to use on the initiator party so we add an option on the journal to define which identifier to use. issue8063 review284021004 --- template/base-cfonb.xml | 44 ++++++++++++++++++++++-------- template/pain.008.001.02-cfonb.xml | 4 +-- 2 files changed, 34 insertions(+), 14 deletions(-) diff --git a/template/base-cfonb.xml b/template/base-cfonb.xml index b1b4caafed..cf3dd42a77 100644 --- a/template/base-cfonb.xml +++ b/template/base-cfonb.xml @@ -3,19 +3,39 @@ this repository contains the full copyright notices and license terms. --> - + - ${party.name[:70]} - - - - ${party.sepa_creditor_identifier_used} - - SEPA - - - - + ${party.name[:70]} + + + + ${identifier['BICOrBEI']} + + ${identifier['Id']} + + ${identifier['SchmeNm']['Cd']} + ${identifier['SchmeNm']['Cd']} + + ${identifier['Issr']} + + + + + ${identifier['DtAndPlcOfBirth']['BirthDt'].isoformat()} + ${identifier['DtAndPlcOfBirth']['PrvcOfBirth']} + ${identifier['DtAndPlcOfBirth']['CityOfBirth']} + ${identifier['DtAndPlcOfBirth']['CtryOfBirth']} + + + ${identifier['Id']} + + ${identifier['SchmeNm']['Cd']} + ${identifier['SchmeNm']['Prtry']} + + ${identifier['Issr']} + + + diff --git a/template/pain.008.001.02-cfonb.xml b/template/pain.008.001.02-cfonb.xml index 70c3d55912..bf142d0c1e 100644 --- a/template/pain.008.001.02-cfonb.xml +++ b/template/pain.008.001.02-cfonb.xml @@ -55,7 +55,7 @@ this repository contains the full copyright notices and license terms. --> ${key['date'].isoformat()} - ${PartyIdentification(group.company.party, id=False)} + ${PartyIdentification(group.company.party)} ${Account(group.journal.sepa_bank_account_number)} @@ -66,7 +66,7 @@ this repository contains the full copyright notices and license terms. --> ${group.journal.sepa_charge_bearer} - ${PartyIdentification(group.company.party, name=False)} + ${PartyIdentification(group.company.party, id='sepa', with_name=False)}