Bug 31615: Allow checkin of items bundles without verifying their contents

This patch adds a button in the "bundle verification" modal to skip
this step and do the checkin anyway.

Test plan:
1. Create an items bundle (see bug 28854 comment 458)
2. Check out this bundle, then return it. The "bundle verification"
   modal should appear
3. Leave the textarea empty and click on "Confirm checkin without
   verifying bundle contents"
4. Confirm that the bundle was correctly returned, and no items were
   marked as lost

Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
This commit is contained in:
Julian Maurice 2022-09-23 10:12:22 +02:00 committed by Tomas Cohen Arazi
parent e91b3fb4b0
commit c0392d881b
Signed by: tomascohen
GPG key ID: 0A272EA1B2F3C15F
2 changed files with 2 additions and 1 deletions

View file

@ -419,7 +419,7 @@ if ($barcode) {
}
# Mark missing bundle items as lost and report unexpected items
if ( $item && $item->is_bundle && $query->param('confirm_items_bundle_return') ) {
if ( $item && $item->is_bundle && $query->param('confirm_items_bundle_return') && !$query->param('do_not_verify_items_bundle_contents') ) {
my $BundleLostValue = C4::Context->preference('BundleLostValue');
my $barcodes = $query->param('verify-items-bundle-contents-barcodes');
my @barcodes = map { s/^\s+|\s+$//gr } ( split /\n/, $barcodes );

View file

@ -510,6 +510,7 @@
[% END %]
[% IF item.onloan %]
<button type="submit" class="btn btn-default"><i class="fa fa-check"></i> Confirm checkin and mark missing items as lost</button>
<button type="submit" class="btn btn-default" name="do_not_verify_items_bundle_contents" value="1"><i class="fa fa-check"></i> Confirm checkin without verifying bundle contents</button>
[% ELSE %]
<button type="submit" class="btn btn-default"><i class="fa fa-check"></i> Confirm inventory check and mark items as lost</button>
[% END %]