[Koha-patches] [PATCH] Bug 8125 - Adds zipcode to address output
Liz Rea
wizzyrea at gmail.com
Fri May 18 19:11:48 CEST 2012
Please test thoroughly - also, I don't know if there is a specific field that SIP expects zipcode to be in. If there is, this patch probably won't fix the issue.
To test:
fetch a valid patron using SIP. The Address field should have the zipcode included.
---
C4/SIP/ILS/Patron.pm | 3 ++-
1 files changed, 2 insertions(+), 1 deletions(-)
diff --git a/C4/SIP/ILS/Patron.pm b/C4/SIP/ILS/Patron.pm
index 99fd6e7..a3c805b 100644
--- a/C4/SIP/ILS/Patron.pm
+++ b/C4/SIP/ILS/Patron.pm
@@ -61,11 +61,12 @@ sub new {
my %ilspatron;
my $adr = $kp->{streetnumber} || '';
my $address = $kp->{address} || '';
+ my $zip = $kp->{zipcode} || '';
my $dob = $kp->{dateofbirth};
$dob and $dob =~ s/-//g; # YYYYMMDD
my $dexpiry = $kp->{dateexpiry};
$dexpiry and $dexpiry =~ s/-//g; # YYYYMMDD
- $adr .= ($adr && $address) ? " $address" : $address;
+ $adr .= ($adr && $address && $zip) ? " $address" : $address;
my $fines_amount = $flags->{CHARGES}->{amount};
$fines_amount = ($fines_amount and $fines_amount > 0) ? $fines_amount : 0;
{
--
1.7.2.5
More information about the Koha-patches
mailing list