[open-ils-commits] r18020 - branches/rel_2_0/Open-ILS/src/perlmods/OpenILS/SIP/Transaction (erickson)

svn at svn.open-ils.org svn at svn.open-ils.org
Sun Sep 26 19:24:36 EDT 2010


Author: erickson
Date: 2010-09-26 19:24:35 -0400 (Sun, 26 Sep 2010)
New Revision: 18020

Modified:
   branches/rel_2_0/Open-ILS/src/perlmods/OpenILS/SIP/Transaction/Checkin.pm
Log:
backport 18017: honor SIP return date as the circ backdate

Modified: branches/rel_2_0/Open-ILS/src/perlmods/OpenILS/SIP/Transaction/Checkin.pm
===================================================================
--- branches/rel_2_0/Open-ILS/src/perlmods/OpenILS/SIP/Transaction/Checkin.pm	2010-09-26 23:23:47 UTC (rev 18019)
+++ branches/rel_2_0/Open-ILS/src/perlmods/OpenILS/SIP/Transaction/Checkin.pm	2010-09-26 23:24:35 UTC (rev 18020)
@@ -71,6 +71,13 @@
 
     my $args = {barcode => $self->{item}->id};
 
+    if($return_date) {
+        # SIP date format is YYYYMMDD.  Translate to ISO8601
+        $return_date =~ s/(\d{4})(\d{2})(\d{2}).*/$1-$2-$3/;
+        syslog('LOG_INFO', "Checking in with backdate $return_date");
+        $args->{backdate} = $return_date;
+    }
+
     if($current_loc) { # SIP client specified a physical location
 
         my $org_id = (defined $org_sn_cache{$current_loc}) ? 



More information about the open-ils-commits mailing list