[Koha-bugs] [Bug 3697] SIP item information response doesn't include due date

bugzilla-daemon at kohaorg.ec2.liblime.com bugzilla-daemon at kohaorg.ec2.liblime.com
Tue Dec 1 10:26:20 CET 2009


http://bugs.koha.org/cgi-bin/bugzilla3/show_bug.cgi?id=3697





--- Comment #4 from Patrick Langer <patrick.langer at easycheck.org>  2009-12-01 09:26:20 ---
I think that MsgType.pm is handling the date format for those date fields
completely wrong. In sub handle_item_information around line 1126 it uses the
timestamp format which looks like "20091201    100633". This is normally the
transaction date format used at the beginning of most SIP2 messages. Fields
like due_date, recall_date or hold_pickup_date are usually in the YYYY-MM-DD
format. MsgType.pm should therefore be changed like this

        if (($i = $item->due_date) != 0) {
-           $resp .= add_field(FID_DUE_DATE, Sip::timestamp($i));
+           $resp .= add_field(FID_DUE_DATE, $i);
        }
        if (($i = $item->recall_date) != 0) {
-           $resp .= add_field(FID_RECALL_DATE, Sip::timestamp($i));
+           $resp .= add_field(FID_RECALL_DATE, $i);
        }
        if (($i = $item->hold_pickup_date) != 0) {
-           $resp .= add_field(FID_HOLD_PICKUP_DATE, Sip::timestamp($i));
+           $resp .= add_field(FID_HOLD_PICKUP_DATE, $i);
        }

This should do the trick.


-- 
Configure bugmail: http://bugs.koha.org/cgi-bin/bugzilla3/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are watching all bug changes.



More information about the Koha-bugs mailing list