View | Details | Raw Unified | Return to bug 22799
Collapse All | Expand All

(-)a/tools/batchMod.pl (-3 / +10 lines)
Lines 257-263 if ($op eq "show"){ Link Here
257
            my $existing_items = Koha::Items->search({ barcode => \@contentlist });
257
            my $existing_items = Koha::Items->search({ barcode => \@contentlist });
258
            @itemnumbers = $existing_items->get_column('itemnumber');
258
            @itemnumbers = $existing_items->get_column('itemnumber');
259
            my %exists = map {$_=>1} $existing_items->get_column('barcode');
259
            my %exists = map {$_=>1} $existing_items->get_column('barcode');
260
            @notfoundbarcodes = grep { !$exists{$_} } @contentlist;
260
            # to avoid problems with case sensitivity
261
            foreach my $barcode (@contentlist) {
262
                $barcode = lc($barcode);
263
            }
264
            @notfoundbarcodes = grep { !$exists{lc($_)} } @contentlist;
261
        }
265
        }
262
        elsif ( $filecontent eq 'itemid_file') {
266
        elsif ( $filecontent eq 'itemid_file') {
263
            @itemnumbers = Koha::Items->search({ itemnumber => \@contentlist })->get_column('itemnumber');
267
            @itemnumbers = Koha::Items->search({ itemnumber => \@contentlist })->get_column('itemnumber');
Lines 278-284 if ($op eq "show"){ Link Here
278
            @itemnumbers = $existing_items->get_column('itemnumber');
282
            @itemnumbers = $existing_items->get_column('itemnumber');
279
            my @barcodes = $existing_items->get_column('barcode');
283
            my @barcodes = $existing_items->get_column('barcode');
280
            my %exists = map {$_=>1} @barcodes;
284
            my %exists = map {$_=>1} @barcodes;
281
            @notfoundbarcodes = grep { !$exists{$_} } @barcodelist;
285
            # to avoid problems with case sensitivity
286
            foreach my $barcode (@barcodelist) {
287
                $barcode = lc($barcode);
288
            }
289
            @notfoundbarcodes = grep { !$exists{lc($_)} } @barcodelist;
282
        }
290
        }
283
    }
291
    }
284
292
285
- 

Return to bug 22799