Lines 515-521
if ( ( $findborrower && $borrowernumber_hold || $findclub && $club_hold )
Link Here
|
515 |
# Send the pickup locations count to the UI, the pickup locations will be pulled using the API |
515 |
# Send the pickup locations count to the UI, the pickup locations will be pulled using the API |
516 |
my $pickup_locations = $item_object->pickup_locations({ patron => $patron }); |
516 |
my $pickup_locations = $item_object->pickup_locations({ patron => $patron }); |
517 |
$item->{pickup_locations_count} = $pickup_locations->count; |
517 |
$item->{pickup_locations_count} = $pickup_locations->count; |
518 |
if ( $item->{pickup_locations_count} > 0 ) { |
518 |
if ( $item->{pickup_locations_count} > 0 || C4::Context->preference('AllowHoldPolicyOverride') ) { |
519 |
$num_items_available++; |
519 |
$num_items_available++; |
520 |
$item->{available} = 1; |
520 |
$item->{available} = 1; |
521 |
# pass the holding branch for use as default |
521 |
# pass the holding branch for use as default |
Lines 537-543
if ( ( $findborrower && $borrowernumber_hold || $findclub && $club_hold )
Link Here
|
537 |
my @pickup_locations = $item_object->pickup_locations({ patron => $patron })->as_list; |
537 |
my @pickup_locations = $item_object->pickup_locations({ patron => $patron })->as_list; |
538 |
$item->{pickup_locations_count} = scalar @pickup_locations; |
538 |
$item->{pickup_locations_count} = scalar @pickup_locations; |
539 |
|
539 |
|
540 |
if ( @pickup_locations ) { |
540 |
if ( @pickup_locations || C4::Context->preference('AllowHoldPolicyOverride') ) { |
541 |
$num_items_available++; |
541 |
$num_items_available++; |
542 |
$item->{override} = 1; |
542 |
$item->{override} = 1; |
543 |
|
543 |
|
544 |
- |
|
|