From: Chris Cormack Date: Wed, 5 Mar 2014 00:45:48 +0000 (+1300) Subject: Getting there, it seems to be doing what it should now X-Git-Url: https://old-git.evergreen-ils.org/?a=commitdiff_plain;h=cbe9c873a81cdc13319a4fddf8281d9d1c2853ad;p=working%2FNCIPServer.git Getting there, it seems to be doing what it should now --- diff --git a/lib/NCIP/ILS/Koha.pm b/lib/NCIP/ILS/Koha.pm index 3ac4288..171d1f1 100644 --- a/lib/NCIP/ILS/Koha.pm +++ b/lib/NCIP/ILS/Koha.pm @@ -58,6 +58,7 @@ sub checkin { iteminformation => $issue, borrower => $borrower }; + return $result; } @@ -153,7 +154,20 @@ sub acceptitem { $result = { success => 0, messages => { NO_HOLD => 1 } }; return $result; } - $result = $self->checkin( $barcode, $branchcode ); + my ( $success, $messages, $issue, $borrower ) = + AddReturn( $barcode, $branch, $exemptfine, $dropbox ); + if ( $messages->{'NotIssued'} ) { + $success = 1 + ; # we do this because we are only doing the return to trigger the reserve + } + + my $result = { + success => $success, + messages => $messages, + iteminformation => $issue, + borrower => $borrower + }; + return $result; } 1; diff --git a/templates/problem.tt b/templates/problem.tt index 99dec61..c8d153b 100644 --- a/templates/problem.tt +++ b/templates/problem.tt @@ -1,4 +1,4 @@ -[% INCLUDE 'includes/header.inc' %] +[%# INCLUDE 'includes/header.inc' %] <[% messagetype %]> [% IF processingerror %]