Lines 71-76
my ( $template, $librarian, $cookie, $flags ) = get_template_and_user(
Link Here
|
71 |
|
71 |
|
72 |
my $sessionID = $query->cookie("CGISESSID"); |
72 |
my $sessionID = $query->cookie("CGISESSID"); |
73 |
my $session = get_session($sessionID); |
73 |
my $session = get_session($sessionID); |
|
|
74 |
my $desk_id = C4::Context->userenv->{"desk_id"} || ''; |
74 |
|
75 |
|
75 |
# Print a reserve slip on this page |
76 |
# Print a reserve slip on this page |
76 |
if ( $query->param('print_slip') ) { |
77 |
if ( $query->param('print_slip') ) { |
Lines 155-161
if ( $query->param('reserve_id') ) {
Link Here
|
155 |
my $diffBranchSend = ($userenv_branch ne $diffBranchReturned) ? $diffBranchReturned : undef; |
156 |
my $diffBranchSend = ($userenv_branch ne $diffBranchReturned) ? $diffBranchReturned : undef; |
156 |
# diffBranchSend tells ModReserveAffect whether document is expected in this library or not, |
157 |
# diffBranchSend tells ModReserveAffect whether document is expected in this library or not, |
157 |
# i.e., whether to apply waiting status |
158 |
# i.e., whether to apply waiting status |
158 |
ModReserveAffect( $itemnumber, $borrowernumber, $diffBranchSend, $reserve_id ); |
159 |
ModReserveAffect( $itemnumber, $borrowernumber, $diffBranchSend, $reserve_id, $desk_id ); |
159 |
} |
160 |
} |
160 |
# check if we have other reserves for this document, if we have a return send the message of transfer |
161 |
# check if we have other reserves for this document, if we have a return send the message of transfer |
161 |
my ( $messages, $nextreservinfo ) = GetOtherReserves($itemnumber); |
162 |
my ( $messages, $nextreservinfo ) = GetOtherReserves($itemnumber); |
Lines 422-428
if ( $messages->{'ResFound'}) {
Link Here
|
422 |
my $biblio = $item->biblio; |
423 |
my $biblio = $item->biblio; |
423 |
|
424 |
|
424 |
my $diffBranchSend = !$branchCheck ? $reserve->{branchcode} : undef; |
425 |
my $diffBranchSend = !$branchCheck ? $reserve->{branchcode} : undef; |
425 |
ModReserveAffect( $reserve->{itemnumber}, $reserve->{borrowernumber}, $diffBranchSend, $reserve->{reserve_id} ); |
426 |
ModReserveAffect( $reserve->{itemnumber}, $reserve->{borrowernumber}, $diffBranchSend, $reserve->{reserve_id}, $desk_id ); |
426 |
my ( $messages, $nextreservinfo ) = GetOtherReserves($reserve->{itemnumber}); |
427 |
my ( $messages, $nextreservinfo ) = GetOtherReserves($reserve->{itemnumber}); |
427 |
|
428 |
|
428 |
$template->param( |
429 |
$template->param( |