Lines 256-262
if ( $query->param('place_reserve') ) {
Link Here
|
256 |
# holdingbranch, force the value $rank and $found. |
256 |
# holdingbranch, force the value $rank and $found. |
257 |
my $rank = $biblioData->{rank}; |
257 |
my $rank = $biblioData->{rank}; |
258 |
if ( $itemNum ne '' ) { |
258 |
if ( $itemNum ne '' ) { |
259 |
$canreserve = 1 if CanItemBeReserved( $borrowernumber, $itemNum ) eq 'OK'; |
259 |
$canreserve = 1 if CanItemBeReserved( $borrowernumber, $itemNum, $branch ) eq 'OK'; |
260 |
$rank = '0' unless C4::Context->preference('ReservesNeedReturns'); |
260 |
$rank = '0' unless C4::Context->preference('ReservesNeedReturns'); |
261 |
my $item = GetItem($itemNum); |
261 |
my $item = GetItem($itemNum); |
262 |
if ( $item->{'holdingbranch'} eq $branch ) { |
262 |
if ( $item->{'holdingbranch'} eq $branch ) { |
Lines 265-271
if ( $query->param('place_reserve') ) {
Link Here
|
265 |
} |
265 |
} |
266 |
} |
266 |
} |
267 |
else { |
267 |
else { |
268 |
$canreserve = 1 if CanBookBeReserved( $borrowernumber, $biblioNum ) eq 'OK'; |
268 |
$canreserve = 1 if CanBookBeReserved( $borrowernumber, $biblioNum, $branch ) eq 'OK'; |
269 |
|
269 |
|
270 |
# Inserts a null into the 'itemnumber' field of 'reserves' table. |
270 |
# Inserts a null into the 'itemnumber' field of 'reserves' table. |
271 |
$itemNum = undef; |
271 |
$itemNum = undef; |
Lines 511-517
foreach my $biblioNum (@biblionumbers) {
Link Here
|
511 |
my $policy_holdallowed = !$itemLoopIter->{already_reserved}; |
511 |
my $policy_holdallowed = !$itemLoopIter->{already_reserved}; |
512 |
$policy_holdallowed &&= |
512 |
$policy_holdallowed &&= |
513 |
IsAvailableForItemLevelRequest($itemInfo,$borr) && |
513 |
IsAvailableForItemLevelRequest($itemInfo,$borr) && |
514 |
CanItemBeReserved($borrowernumber,$itemNum) eq 'OK'; |
514 |
CanItemBeReserved($borrowernumber,$itemNum,$branch) eq 'OK'; |
515 |
|
515 |
|
516 |
if ($policy_holdallowed) { |
516 |
if ($policy_holdallowed) { |
517 |
if ( my $hold_allowed = OPACItemHoldsAllowed( $itemInfo, $borr ) ) { |
517 |
if ( my $hold_allowed = OPACItemHoldsAllowed( $itemInfo, $borr ) ) { |
Lines 548-554
foreach my $biblioNum (@biblionumbers) {
Link Here
|
548 |
$biblioLoopIter{already_patron_possession} = 1; |
548 |
$biblioLoopIter{already_patron_possession} = 1; |
549 |
} |
549 |
} |
550 |
|
550 |
|
551 |
$biblioLoopIter{holdable} &&= CanBookBeReserved($borrowernumber,$biblioNum) eq 'OK'; |
551 |
$biblioLoopIter{holdable} &&= CanBookBeReserved($borrowernumber,$biblioNum,$branch) eq 'OK'; |
552 |
|
552 |
|
553 |
# For multiple holds per record, if a patron has previously placed a hold, |
553 |
# For multiple holds per record, if a patron has previously placed a hold, |
554 |
# the patron can only place more holds of the same type. That is, if the |
554 |
# the patron can only place more holds of the same type. That is, if the |
555 |
- |
|
|