fixing MARCmodbiblio API and reindenting code
[koha_gimpoz] / C4 / Stats.pm
index 3551824..accae1c 100644 (file)
@@ -123,8 +123,9 @@ sub circrep {
   my $i=0;
   my @results;
   while (my $data=$sth->fetchrow_hashref){
-    $results[$i]="$data->{'datetime'}\t$data->{'branch'}";
-    $i++;
+       my %tempvalue;
+    $tempvalue{'value'}="$data->{'datetime'}\t$data->{'branch'}";
+    push(@results, \%tempvalue);
   }
   $sth->finish;
 #  print $query;
@@ -165,7 +166,7 @@ sub TotalOwing{
   my $dbh = C4::Context->dbh;
   my $query="Select sum(amountoutstanding) from accountlines";
   if ($type eq 'fine'){
-    $query=$query." where accounttype='F' or accounttype='FN'";        # FIXME - .=
+    $query .= " where accounttype='F' or accounttype='FN'";
   }
   my $sth=$dbh->prepare($query);
 #  print $query;
@@ -184,7 +185,7 @@ sub TotalPaid {
 or accounttype ='W')
   and accountlines.borrowernumber = borrowers.borrowernumber";
   if ($time eq 'today'){
-    $query=$query." and date = now()";                         # FIXME - .=
+    $query .= " and date = now()";
   } else {
     $query.=" and date='$time'";
   }