Bug 26643: Notify librarian of completed transfers
It came to light that it's not clear to all users that a checkin results in the completion of a transfer if one exists for the item being checked in. This patch adds such a notification to the error messages loop to highlight that the item has been recieved from it's sending brnach. To test 1/ Setup a transfer from branch A to branch B 2/ Check the item in at branch B 3/ Note that a new message appears in the 'Check in message' alert box saying "Item recieved from branch A" 4/ Signoff Signed-off-by: Sally <sally.healey@cheshiresharedservices.gov.uk> Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de> Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
This commit is contained in:
parent
d1825a1fd8
commit
bbd86d7a30
|
|
@ -2053,7 +2053,7 @@ sub AddReturn {
|
|||
# check if we have a transfer for this document
|
||||
my ($datesent,$frombranch,$tobranch) = GetTransfers( $item->itemnumber );
|
||||
|
||||
# if we have a transfer to do, we update the line of transfers with the datearrived
|
||||
# if we have a transfer to complete, we update the line of transfers with the datearrived
|
||||
my $is_in_rotating_collection = C4::RotatingCollections::isItemInAnyCollection( $item->itemnumber );
|
||||
if ($datesent) {
|
||||
# At this point we will either fill the transfer or it is a wrong transfer
|
||||
|
|
@ -2064,6 +2064,7 @@ sub AddReturn {
|
|||
"UPDATE branchtransfers SET datearrived = now() WHERE itemnumber= ? AND datearrived IS NULL"
|
||||
);
|
||||
$sth->execute( $item->itemnumber );
|
||||
$messages->{'TransferArrived'} = $frombranch;
|
||||
} else {
|
||||
$messages->{'WrongTransfer'} = $tobranch;
|
||||
$messages->{'WrongTransferItem'} = $item->itemnumber;
|
||||
|
|
|
|||
|
|
@ -511,6 +511,9 @@ foreach my $code ( keys %$messages ) {
|
|||
elsif ( $code eq 'TransferTrigger' ) {
|
||||
; # Handled alongside NeedsTransfer
|
||||
}
|
||||
elsif ( $code eq 'TransferArrived' ) {
|
||||
$err{transferred} = $messages->{'TransferArrived'};
|
||||
}
|
||||
elsif ( $code eq 'Wrongbranch' ) {
|
||||
}
|
||||
elsif ( $code eq 'Debarred' ) {
|
||||
|
|
|
|||
|
|
@ -255,6 +255,9 @@
|
|||
[% IF ( errmsgloo.localuse) %]
|
||||
<p class="problem ret_localuse">Local use recorded</p>
|
||||
[% END %]
|
||||
[% IF ( errmsgloo.transferred ) %]
|
||||
<p class="problem ret_transferred">Item recieved from [% Branches.GetName( errmsgloo.transferred ) | html %]</p>
|
||||
[% END %]
|
||||
[% IF ( errmsgloo.waslost ) %]
|
||||
[% IF Koha.Preference('BlockReturnOfLostItems') %]
|
||||
<p class="problem ret_blocked">Item is lost, cannot be checked in.</p>
|
||||
|
|
|
|||
Loading…
Reference in New Issue