|
Lines 442-451
sub CanItemBeReserved {
Link Here
|
| 442 |
return { status => 'tooManyReserves', limit => $rule->rule_value} if $total_holds_count >= $rule->rule_value; |
442 |
return { status => 'tooManyReserves', limit => $rule->rule_value} if $total_holds_count >= $rule->rule_value; |
| 443 |
} |
443 |
} |
| 444 |
|
444 |
|
| 445 |
my $circ_control_branch = |
445 |
my $reserves_control_branch = |
| 446 |
GetReservesControlBranch( $item->unblessed(), $borrower ); |
446 |
GetReservesControlBranch( $item->unblessed(), $borrower ); |
| 447 |
my $branchitemrule = |
447 |
my $branchitemrule = |
| 448 |
C4::Circulation::GetBranchItemRule( $circ_control_branch, $item->itype ); # FIXME Should not be item->effective_itemtype? |
448 |
C4::Circulation::GetBranchItemRule( $reserves_control_branch, $item->itype ); # FIXME Should not be item->effective_itemtype? |
| 449 |
|
449 |
|
| 450 |
if ( $branchitemrule->{holdallowed} == 0 ) { |
450 |
if ( $branchitemrule->{holdallowed} == 0 ) { |
| 451 |
return { status => 'notReservable' }; |
451 |
return { status => 'notReservable' }; |
|
Lines 1200-1207
sub IsAvailableForItemLevelRequest {
Link Here
|
| 1200 |
my $any_available = 0; |
1200 |
my $any_available = 0; |
| 1201 |
|
1201 |
|
| 1202 |
foreach my $i (@items) { |
1202 |
foreach my $i (@items) { |
| 1203 |
my $circ_control_branch = GetReservesControlBranch( $i->unblessed(), $borrower ); |
1203 |
my $reserves_control_branch = GetReservesControlBranch( $i->unblessed(), $borrower ); |
| 1204 |
my $branchitemrule = C4::Circulation::GetBranchItemRule( $circ_control_branch, $i->itype ); |
1204 |
my $branchitemrule = C4::Circulation::GetBranchItemRule( $reserves_control_branch, $i->itype ); |
| 1205 |
|
1205 |
|
| 1206 |
$any_available = 1 |
1206 |
$any_available = 1 |
| 1207 |
unless $i->itemlost |
1207 |
unless $i->itemlost |
| 1208 |
- |
|
|