Revision 7ef224c0
Von Cem Aydin vor 5 Monaten hinzugefügt
bin/mozilla/sepa.pl | ||
---|---|---|
273 | 273 |
my %unique_vendor_types; |
274 | 274 |
for my $bt (@$bank_transfers) { |
275 | 275 |
my $uid = "$bt->{vc_id}_$bt->{type}"; |
276 |
|
|
277 |
# if qr-bill get iban from qr-bill data to display in vendor account information, |
|
278 |
# important for manual verification |
|
279 |
my $qr_iban; |
|
280 |
if ($bt->{type} eq 'QRBILL') { |
|
281 |
my $qr_bill_data = SL::Helper::QrBillParser->new($bt->{qrbill_data}); |
|
282 |
$qr_iban = $qr_bill_data->{creditor_information}->{iban}; |
|
283 |
} |
|
284 |
|
|
276 | 285 |
$unique_vendor_types{$uid} = { |
277 | 286 |
vc_id => $bt->{vc_id}, |
278 |
type => $bt->{type} |
|
287 |
type => $bt->{type}, |
|
288 |
qr_iban => $qr_iban, |
|
279 | 289 |
} unless defined $unique_vendor_types{$uid}; |
280 | 290 |
} |
281 | 291 |
|
... | ... | |
287 | 297 |
# combine bank info with unique vendor types |
288 | 298 |
for my $unique_vendor (values %unique_vendor_types) { |
289 | 299 |
$vendors->{$unique_vendor->{vc_id}}->{type} = $unique_vendor->{type}; |
300 |
if ($unique_vendor->{type} eq 'QRBILL') { |
|
301 |
$vendors->{$unique_vendor->{vc_id}}->{qr_iban} = $unique_vendor->{qr_iban}; |
|
302 |
} |
|
290 | 303 |
} |
291 | 304 |
|
292 | 305 |
# validate bank info for unique vendor types |
Auch abrufbar als: Unified diff
Schweizer Banküberweisung via XML: IBAN von QR-Rechnungen zur Überprüfung der Kontoinformationen anzeigen