Merge remote-tracking branch 'origin/new/bug_5347'
[koha_gimpoz] / C4 / Circulation.pm
index 9c43f36..6ca860d 100644 (file)
@@ -36,7 +36,7 @@ use C4::Message;
 use C4::Debug;
 use C4::Branch; # GetBranches
 use C4::Log; # logaction
-
+use C4::Koha qw(GetAuthorisedValueByCode);
 use Data::Dumper;
 use Koha::DateUtils;
 use Koha::Calendar;
@@ -848,6 +848,9 @@ sub CanBookBeIssued {
     {
         $issuingimpossible{RESTRICTED} = 1;
     }
+    if ( $item->{'itemlost'} ) {
+        $needsconfirmation{ITEM_LOST} = GetAuthorisedValueByCode( 'LOST', $item->{'itemlost'} );
+    }
     if ( C4::Context->preference("IndependantBranches") ) {
         my $userenv = C4::Context->userenv;
         if ( ($userenv) && ( $userenv->{flags} % 2 != 1 ) ) {