MARC search fixes and improvements. Now, ALL searches are indexed and should be very...
[koha_fer] / stats.pl
index c24cfcf..49c604d 100755 (executable)
--- a/stats.pl
+++ b/stats.pl
@@ -1,8 +1,28 @@
 #!/usr/bin/perl
 
+# $Id$
+
 #written 14/1/2000
 #script to display reports
 
+
+# Copyright 2000-2002 Katipo Communications
+#
+# This file is part of Koha.
+#
+# Koha is free software; you can redistribute it and/or modify it under the
+# terms of the GNU General Public License as published by the Free Software
+# Foundation; either version 2 of the License, or (at your option) any later
+# version.
+#
+# Koha is distributed in the hope that it will be useful, but WITHOUT ANY
+# WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR
+# A PARTICULAR PURPOSE.  See the GNU General Public License for more details.
+#
+# You should have received a copy of the GNU General Public License along with
+# Koha; if not, write to the Free Software Foundation, Inc., 59 Temple Place,
+# Suite 330, Boston, MA  02111-1307 USA
+
 use C4::Stats;
 use strict;
 use Date::Manip;
@@ -62,7 +82,7 @@ while ($i<$count){
   my $temptotalr=0;
   my $temptotalres=0;
   my $temptotalren=0;
-  my $temptotalw=0;   
+  my $temptotalw=0;
   for (my $i2=0;$i2<$count;$i2++){
      $charge+=$charges[$i2]->{'amount'};
       print mktablerow(6,'red',$charges[$i2]->{'description'},$charges[$i2]->{'accounttype'},$charges[$i2]->{'timestamp'},
@@ -80,7 +100,7 @@ while ($i<$count){
         if ($charges[$i2]->{'accounttype'} eq 'R'){
          $temptotalren+=$charges[$i2]->{'amount'}-$charges[$i2]->{'amountoutstanding'};
         }
-     }   
+     }
   }
 
 #  my $branch=
@@ -116,7 +136,7 @@ while ($i<$count){
      my $time="$hour:$min:$sec";
          my $time2="$payments[$i]{'date'}";
      my $branch=Getpaidbranch($time2,$payments[$i]{'borrowernumber'});
-    
+
     if ($payments[$i]{'accounttype'} eq 'W'){
       $totalw+=$payments[$i]{'amount'};
     } else {
@@ -135,7 +155,7 @@ while ($i<$count){
     }
 #    my $time2="$payments[$i]{'date'} $time";
 
-  
+
     print mktablerow(6,'white',"$payments[$i]{'firstname'} <b>$payments[$i]{'surname'}</b>",
     ,$payments[$i]{'accounttype'},"$payments[$i]{'date'} $time",$payments[$i]{'amount'}
     ,$branch);
@@ -143,7 +163,7 @@ while ($i<$count){
     $oldtime=$payments[$i]{'timestamp'};
     $bornum=$payments[$i]{'borrowernumber'};
     $i++;
-  
+
   }
   print mktablerow('6','white','','','','','','');
 }