From 3d6e2c129fa174f3caf0cd73592a655014509c75 Mon Sep 17 00:00:00 2001 From: Katrin Fischer Date: Thu, 24 Sep 2020 23:52:33 +0200 Subject: [PATCH] Bug 24780: Make items.stocknumber show up in batch item modification It looks like the field was intentionally removed from the list of batch editable fields in the past. This makes sense as we used to have a unique index on it at some point - but we do have no more. This removes the exception so that the invendory number behaves like the other fields on the batch item edit form. To test: - Create some items with and without stocknumber - Go to tools > batch item modification - Enter the barcodes of your selected items in the list or upload a file with them - Verify that the stocknumber/inventory number is not showing in the item edit form below - Apply patch - Reload the page - inventory number is there now - Batch edit the inventory number and verify it works as expected Signed-off-by: Andrew Fuerste-Henry Signed-off-by: Martin Renvoize Signed-off-by: Jonathan Druart (cherry picked from commit 0afcf3936a6ceeb865fdf0159cf54618400847d7) Signed-off-by: Lucas Gass (cherry picked from commit 1754df0b1959b2e3514f771e7cd499d13c847a0c) Signed-off-by: Aleisha Amohia --- tools/batchMod.pl | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/tools/batchMod.pl b/tools/batchMod.pl index 803f1b8726..4e27d47237 100755 --- a/tools/batchMod.pl +++ b/tools/batchMod.pl @@ -330,9 +330,8 @@ foreach my $tag (sort keys %{$tagslib}) { next if IsMarcStructureInternal( $tagslib->{$tag}{$subfield} ); next if (not $allowAllSubfields and $restrictededition && !grep { $tag . '$' . $subfield eq $_ } @subfieldsToAllow ); next if ($tagslib->{$tag}->{$subfield}->{'tab'} ne "10"); - # barcode and stocknumber are not meant to be batch-modified - next if $tagslib->{$tag}->{$subfield}->{'kohafield'} eq 'items.barcode'; - next if $tagslib->{$tag}->{$subfield}->{'kohafield'} eq 'items.stocknumber'; + # barcode is not meant to be batch-modified + next if $tagslib->{$tag}->{$subfield}->{'kohafield'} eq 'items.barcode'; my %subfield_data; my $index_subfield = int(rand(1000000)); -- 2.20.1