|
Lines 285-291
if ( $query->param('place_reserve') ) {
Link Here
|
| 285 |
} |
285 |
} |
| 286 |
|
286 |
|
| 287 |
unless ( $can_place_hold_if_available_at_pickup ) { |
287 |
unless ( $can_place_hold_if_available_at_pickup ) { |
| 288 |
$canreserve = 0 if Koha::Items->search({ biblionumber => $biblioNum, holdingbranch => $branch })->count; |
288 |
my $items_in_this_library = Koha::Items->search({ biblionumber => $biblioNum, holdingbranch => $branch }); |
|
|
289 |
my $nb_of_items_issued = $items_in_this_library->search({ 'issue.itemnumber' => { not => undef }}, { join => 'issue' })->count; |
| 290 |
if ( $items_in_this_library->count > $nb_of_items_issued ) { |
| 291 |
$canreserve = 0 |
| 292 |
} |
| 289 |
} |
293 |
} |
| 290 |
|
294 |
|
| 291 |
my $itemtype = $query->param('itemtype') || undef; |
295 |
my $itemtype = $query->param('itemtype') || undef; |
|
Lines 532-538
foreach my $biblioNum (@biblionumbers) {
Link Here
|
| 532 |
$numCopiesAvailable++; |
536 |
$numCopiesAvailable++; |
| 533 |
|
537 |
|
| 534 |
unless ( $can_place_hold_if_available_at_pickup ) { |
538 |
unless ( $can_place_hold_if_available_at_pickup ) { |
| 535 |
push @not_available_at, $itemInfo->{holdingbranch}; |
539 |
my $items_in_this_library = Koha::Items->search({ biblionumber => $itemInfo->{biblionumber}, holdingbranch => $itemInfo->{holdingbranch} }); |
|
|
540 |
my $nb_of_items_issued = $items_in_this_library->search({ 'issue.itemnumber' => { not => undef }}, { join => 'issue' })->count; |
| 541 |
if ( $items_in_this_library->count > $nb_of_items_issued ) { |
| 542 |
push @not_available_at, $itemInfo->{holdingbranch}; |
| 543 |
} |
| 536 |
} |
544 |
} |
| 537 |
} |
545 |
} |
| 538 |
|
546 |
|
| 539 |
- |
|
|