Browse Source

Modifying 0 value display in templates

3.0.x
hdl 18 years ago
parent
commit
6c3f4a3e58
  1. 12
      koha-tmpl/intranet-tmpl/default/en/reports/catalogue_stats.tmpl
  2. 10
      reports/catalogue_stats.pl

12
koha-tmpl/intranet-tmpl/default/en/reports/catalogue_stats.tmpl

@ -24,9 +24,15 @@
<!-- TMPL_IF NAME="hilighted" --><td class="hilighted"><!-- TMPL_ELSE --><td><!-- /TMPL_IF -->
<!-- TMPL_VAR NAME="rowtitle" --></td>
<!-- TMPL_LOOP NAME="loopcell" -->
<!-- TMPL_IF NAME="hilighted" --><td class="numberhilighted"><!-- TMPL_ELSE --><td class="number"><!-- /TMPL_IF -->
<!-- TMPL_VAR NAME="value" -->
</td>
<!--TMPL_IF NAME="value" -->
<!-- TMPL_IF NAME="hilighted" --><td class="numberhilighted"><!-- TMPL_ELSE --><td class="number"><!-- /TMPL_IF -->
<!-- TMPL_VAR NAME="value" -->
</td>
<!--TMPL_ELSE-->
<!-- TMPL_IF NAME="hilighted" --><td class="numberhilighted"><!-- TMPL_ELSE --><td class="number"><!-- /TMPL_IF -->
&nbsp;
</td>
<!--/TMPL_IF-->
<!-- /TMPL_LOOP -->
<!-- TMPL_IF NAME="hilighted" --><td class="numberhilighted"><!-- TMPL_ELSE --><td class="number"><!-- /TMPL_IF -->
<!-- TMPL_VAR NAME="totalrow" -->

10
reports/catalogue_stats.pl

@ -398,8 +398,8 @@ sub calculate {
my %cell;
if ($celvalue) {
$cell{rowtitle} = $celvalue;
} else {
$cell{rowtitle} = "";
# } else {
# $cell{rowtitle} = "";
}
$cell{totalrow} = 0;
push @loopline, \%cell;
@ -440,8 +440,8 @@ sub calculate {
my %ft;
if ($celvalue) {
$cell{coltitle} = $celvalue;
} else {
$cell{coltitle} = "";
# } else {
# $cell{coltitle} = "";
}
$ft{totalcol} = 0;
push @loopcol, \%cell;
@ -605,7 +605,7 @@ sub calculate {
# and the number matches the number of columns
foreach my $col ( @loopcol ) {
my $value =$table{$row}->{($col->{coltitle} eq "NULL")?"zzEMPTY":$col->{coltitle}};
push @loopcell, {value => ($value)?$value:"" } ;
push @loopcell, {value => $value } ;
}
push @looprow,{ 'rowtitle' => ($row eq "zzEMPTY")?"NULL":$row,
'loopcell' => \@loopcell,

Loading…
Cancel
Save