Skip to content

Commit

Permalink
[IMP] tolerence of data format in mako. Considering an empty country …
Browse files Browse the repository at this point in the history
…is company's country and we format iban number by removing spaces.
  • Loading branch information
yvaucher committed Feb 12, 2014
1 parent 14dfe22 commit d7b734a
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions l10n_ch_sepa/base_sepa/base_template/pain.001.001.03.xml.mako
Original file line number Diff line number Diff line change
Expand Up @@ -80,14 +80,14 @@
<StrtNm>${partner.street}</StrtNm>
<PstCd>${partner.zip}</PstCd>
<TwnNm>${partner.city}</TwnNm>
<Ctry>${partner.country_id.code}</Ctry>
<Ctry>${partner.country_id.code or partner.company_id.country_id.code}</Ctry>
</PstlAdr>
</%def>\
\
<%def name="acc_id(bank_acc)">
<Id>
% if bank_acc.iban:
<IBAN>${bank_acc.iban}</IBAN>
<IBAN>${bank_acc.iban.replace(" ","")}</IBAN>
% else:
<Othr>
<Id>${bank_acc.get_account_number()}</Id>
Expand Down

0 comments on commit d7b734a

Please sign in to comment.