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

(-)a/tools/inventory.pl (-9 / +10 lines)
Lines 35-40 use C4::Circulation qw( barcodedecode AddReturn ); Link Here
35
use C4::Reports::Guided qw( );
35
use C4::Reports::Guided qw( );
36
use C4::Charset         qw( NormalizeString );
36
use C4::Charset         qw( NormalizeString );
37
37
38
use Koha::I18N qw(__);
38
use Koha::Biblios;
39
use Koha::Biblios;
39
use Koha::DateUtils qw( dt_from_string );
40
use Koha::DateUtils qw( dt_from_string );
40
use Koha::Database::Columns;
41
use Koha::Database::Columns;
Lines 445-451 if ( defined $input->param('CSVexport') && $input->param('CSVexport') eq 'on' ) Link Here
445
        my ( $table, $column ) = split '\.', $key;
446
        my ( $table, $column ) = split '\.', $key;
446
        push @translated_keys, NormalizeString( $columns->{$table}->{$column} // '' );
447
        push @translated_keys, NormalizeString( $columns->{$table}->{$column} // '' );
447
    }
448
    }
448
    push @translated_keys, 'Problem' if $uploadbarcodes;
449
    push @translated_keys, __('Problem') if $uploadbarcodes;
449
450
450
    $csv->combine(@translated_keys);
451
    $csv->combine(@translated_keys);
451
    print $csv->string, "\n";
452
    print $csv->string, "\n";
Lines 460-478 if ( defined $input->param('CSVexport') && $input->param('CSVexport') eq 'on' ) Link Here
460
        my $errstr = '';
461
        my $errstr = '';
461
        foreach my $key ( keys %{ $item->{problems} } ) {
462
        foreach my $key ( keys %{ $item->{problems} } ) {
462
            if ( $key eq 'wrongplace' ) {
463
            if ( $key eq 'wrongplace' ) {
463
                $errstr .= "wrong place,";
464
                $errstr .= __("wrong place") . ",";
464
            } elsif ( $key eq 'changestatus' ) {
465
            } elsif ( $key eq 'changestatus' ) {
465
                $errstr .= "unselected notforloan status $item->{notforloan},";
466
                $errstr .= __("unselected notforloan status") . "  $item->{notforloan},";
466
            } elsif ( $key eq 'not_scanned' ) {
467
            } elsif ( $key eq 'not_scanned' ) {
467
                $errstr .= "missing,";
468
                $errstr .= __("missing") . ",";
468
            } elsif ( $key eq 'no_barcode' ) {
469
            } elsif ( $key eq 'no_barcode' ) {
469
                $errstr .= "no barcode,";
470
                $errstr .= __("no barcode") . ",";
470
            } elsif ( $key eq 'checkedout' ) {
471
            } elsif ( $key eq 'checkedout' ) {
471
                $errstr .= "checked out,";
472
                $errstr .= __("checked out") . ",";
472
            } elsif ( $key eq 'out_of_order' ) {
473
            } elsif ( $key eq 'out_of_order' ) {
473
                $errstr .= "shelved out of order,";
474
                $errstr .= __("shelved out of order") . ",";
474
            } elsif ( $key eq 'lost' ) {
475
            } elsif ( $key eq 'lost' ) {
475
                $errstr .= "item was lost";
476
                $errstr .= __("item was lost");
476
            }
477
            }
477
        }
478
        }
478
479
Lines 488-493 if ( defined $input->param('CSVexport') && $input->param('CSVexport') eq 'on' ) Link Here
488
        if ( $error->{'ERR_BARCODE'} ) {
489
        if ( $error->{'ERR_BARCODE'} ) {
489
            push @line, map { $_ eq 'barcode' ? $error->{'barcode'} : '' } @keys;
490
            push @line, map { $_ eq 'barcode' ? $error->{'barcode'} : '' } @keys;
490
            push @line, "barcode not found";
491
            push @line, "barcode not found";
492
            push @line, __("barcode not found");
491
            $csv->combine(@line);
493
            $csv->combine(@line);
492
            print $csv->string, "\n";
494
            print $csv->string, "\n";
493
        }
495
        }
494
- 

Return to bug 33856