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

(-)a/reports/issues_stats.pl (-6 / +4 lines)
Lines 88-93 $sep = "\t" if ($sep eq 'tabulation'); Link Here
88
$template->param(do_it => $do_it,
88
$template->param(do_it => $do_it,
89
);
89
);
90
90
91
our $itemtypes = { map { $_->{itemtype} => $_ } @{ Koha::ItemTypes->search_with_localization->unblessed } };
92
91
our @patron_categories = Koha::Patron::Categories->search_limited({}, {order_by => ['description']});
93
our @patron_categories = Koha::Patron::Categories->search_limited({}, {order_by => ['description']});
92
94
93
our $locations = { map { ( $_->{authorised_value} => $_->{lib} ) } Koha::AuthorisedValues->get_descriptions_by_koha_field( { frameworkcode => '', kohafield => 'items.location' }, { order_by => ['description'] } ) };
95
our $locations = { map { ( $_->{authorised_value} => $_->{lib} ) } Koha::AuthorisedValues->get_descriptions_by_koha_field( { frameworkcode => '', kohafield => 'items.location' }, { order_by => ['description'] } ) };
Lines 151-159 my @values; Link Here
151
my %labels;
153
my %labels;
152
my %select;
154
my %select;
153
155
154
# create itemtype arrayref for <select>.
155
our $itemtypes = Koha::ItemTypes->search_with_localization;
156
157
    # location list
156
    # location list
158
my @locations;
157
my @locations;
159
foreach (sort keys %$locations) {
158
foreach (sort keys %$locations) {
Lines 360-366 sub calculate { Link Here
360
        $cell{rowtitle_display} =
359
        $cell{rowtitle_display} =
361
            ( $line =~ /ccode/ )    ? $ccodes->{$celvalue}
360
            ( $line =~ /ccode/ )    ? $ccodes->{$celvalue}
362
          : ( $line =~ /location/ ) ? $locations->{$celvalue}
361
          : ( $line =~ /location/ ) ? $locations->{$celvalue}
363
          : ( $line =~ /itemtype/ ) ? $itemtypes->{$celvalue}->{description}
362
          : ( $line =~ /itemtype/ ) ? $itemtypes->{$celvalue}->{translated_description}
364
          :                           $celvalue;                               # default fallback
363
          :                           $celvalue;                               # default fallback
365
        if ( $line =~ /sort1/ ) {
364
        if ( $line =~ /sort1/ ) {
366
            foreach (@$Bsort1) {
365
            foreach (@$Bsort1) {
Lines 449-455 sub calculate { Link Here
449
        $cell{coltitle_display} =
448
        $cell{coltitle_display} =
450
            ( $column =~ /ccode/ )    ? $ccodes->{$celvalue}
449
            ( $column =~ /ccode/ )    ? $ccodes->{$celvalue}
451
          : ( $column =~ /location/ ) ? $locations->{$celvalue}
450
          : ( $column =~ /location/ ) ? $locations->{$celvalue}
452
          : ( $column =~ /itemtype/ ) ? $itemtypes->{$celvalue}->{description}
451
          : ( $column =~ /itemtype/ ) ? $itemtypes->{$celvalue}->{translated_description}
453
          :                             $celvalue;                               # default fallback
452
          :                             $celvalue;                               # default fallback
454
        if ( $column =~ /sort1/ ) {
453
        if ( $column =~ /sort1/ ) {
455
            foreach (@$Bsort1) {
454
            foreach (@$Bsort1) {
456
- 

Return to bug 19671