|
Lines 36-42
use C4::Message;
Link Here
|
| 36 |
use C4::Debug; |
36 |
use C4::Debug; |
| 37 |
use C4::Branch; # GetBranches |
37 |
use C4::Branch; # GetBranches |
| 38 |
use C4::Log; # logaction |
38 |
use C4::Log; # logaction |
| 39 |
use C4::Koha qw(GetAuthorisedValueByCode); |
39 |
use C4::Koha qw( |
|
|
40 |
GetAuthorisedValueByCode |
| 41 |
GetAuthValCode |
| 42 |
GetKohaAuthorisedValueLib |
| 43 |
); |
| 40 |
use C4::Overdues qw(CalcFine UpdateFine); |
44 |
use C4::Overdues qw(CalcFine UpdateFine); |
| 41 |
use Algorithm::CheckDigits; |
45 |
use Algorithm::CheckDigits; |
| 42 |
|
46 |
|
|
Lines 833-840
sub CanBookBeIssued {
Link Here
|
| 833 |
{ |
837 |
{ |
| 834 |
if(!C4::Context->preference("AllowNotForLoanOverride")){ |
838 |
if(!C4::Context->preference("AllowNotForLoanOverride")){ |
| 835 |
$issuingimpossible{NOT_FOR_LOAN} = 1; |
839 |
$issuingimpossible{NOT_FOR_LOAN} = 1; |
|
|
840 |
$issuingimpossible{item_notforloan} = $item->{'notforloan'}; |
| 836 |
}else{ |
841 |
}else{ |
| 837 |
$needsconfirmation{NOT_FOR_LOAN_FORCING} = 1; |
842 |
$needsconfirmation{NOT_FOR_LOAN_FORCING} = 1; |
|
|
843 |
$needsconfirmation{item_notforloan} = $item->{'notforloan'}; |
| 838 |
} |
844 |
} |
| 839 |
} |
845 |
} |
| 840 |
elsif ( !$item->{'notforloan'} ){ |
846 |
elsif ( !$item->{'notforloan'} ){ |
|
Lines 848-863
sub CanBookBeIssued {
Link Here
|
| 848 |
if ($notforloan->{'notforloan'}) { |
854 |
if ($notforloan->{'notforloan'}) { |
| 849 |
if (!C4::Context->preference("AllowNotForLoanOverride")) { |
855 |
if (!C4::Context->preference("AllowNotForLoanOverride")) { |
| 850 |
$issuingimpossible{NOT_FOR_LOAN} = 1; |
856 |
$issuingimpossible{NOT_FOR_LOAN} = 1; |
|
|
857 |
$issuingimpossible{itemtype_notforloan} = $item->{'itype'}; |
| 851 |
} else { |
858 |
} else { |
| 852 |
$needsconfirmation{NOT_FOR_LOAN_FORCING} = 1; |
859 |
$needsconfirmation{NOT_FOR_LOAN_FORCING} = 1; |
|
|
860 |
$needsconfirmation{itemtype_notforloan} = $item->{'itype'}; |
| 853 |
} |
861 |
} |
| 854 |
} |
862 |
} |
| 855 |
} |
863 |
} |
| 856 |
elsif ($biblioitem->{'notforloan'} == 1){ |
864 |
elsif ($biblioitem->{'notforloan'} == 1){ |
| 857 |
if (!C4::Context->preference("AllowNotForLoanOverride")) { |
865 |
if (!C4::Context->preference("AllowNotForLoanOverride")) { |
| 858 |
$issuingimpossible{NOT_FOR_LOAN} = 1; |
866 |
$issuingimpossible{NOT_FOR_LOAN} = 1; |
|
|
867 |
$issuingimpossible{itemtype_notforloan} = $biblioitem->{'itemtype'}; |
| 859 |
} else { |
868 |
} else { |
| 860 |
$needsconfirmation{NOT_FOR_LOAN_FORCING} = 1; |
869 |
$needsconfirmation{NOT_FOR_LOAN_FORCING} = 1; |
|
|
870 |
$needsconfirmation{itemtype_notforloan} = $biblioitem->{'itemtype'}; |
| 861 |
} |
871 |
} |
| 862 |
} |
872 |
} |
| 863 |
} |
873 |
} |