Added magic RCS comment.
authorarensb <arensb>
Sun, 13 Oct 2002 07:31:21 +0000 (07:31 +0000)
committerarensb <arensb>
Sun, 13 Oct 2002 07:31:21 +0000 (07:31 +0000)
Removed trailing whitespace.

48 files changed:
C4/Circmain.pm
C4/Database.pm
C4/Groups.pm
C4/Security.pm
acqui.simple/addbiblio.pl
acqui.simple/addbooks.pl
acqui.simple/addbookslccn.pl
acqui.simple/additem.pl
acqui.simple/marcimport.pl
acqui.simple/processz3950queue
acqui.simple/saveitem.pl
acqui/acquire.pl
acqui/basket.pl
acqui/newbasket.pl
acqui/order.pl
acqui/receive.pl
acqui/recieveorder.pl
acqui/supplier.pl
bookcount.pl
boraccount.pl
currency.pl
deletemem.pl
groups.pl
installer-lite.pl
installer.pl
koha.upgrade
member.pl
memberentry.pl
modbib.pl
modbibitem.pl
moditem.pl
moredetail.pl
moremember.pl
newimember.pl
overdue.pl
pay.pl
renewscript.pl
reports.pl
request.pl
showbudget.pl
stats.pl
stats2.pl
subjectsearch.pl
tidyaccounts.pl
updatebibitem.pl
updatecharges.pl
updateitem.pl
updatewebsite.pl

index 13e708b..2716699 100755 (executable)
@@ -1,6 +1,8 @@
-package C4::Circmain; #assumes C4/Circulation
+package C4::Circmain;
 
-#package to deal with circulation 
+# $Id$
+
+#package to deal with circulation
 
 
 # Copyright 2000-2002 Katipo Communications
@@ -36,10 +38,10 @@ use C4::InterfaceCDK;
 use C4::Security;
 
 use vars qw($VERSION @ISA @EXPORT);
-  
+
 # set the version for version checking
 $VERSION = 0.01;
-    
+
 @ISA = qw(Exporter);
 @EXPORT = qw(&Start_circ);
 
@@ -55,32 +57,29 @@ sub Start_circ{
   my $data;
   while ($donext ne 'Quit') {
     if ($donext  eq "Circ") {
-      #($reason,$data) = menu($env,'console','Circulation', 
+      #($reason,$data) = menu($env,'console','Circulation',
       #  ('Issues','Returns','Borrower Enquiries','Reserves','Log In'));
       #&startint($env,"Menu");
       ($reason,$data) = menu($env,'console','Circulation',
-        ('Issues','Returns','Select Branch','Select Printer')); 
+        ('Issues','Returns','Select Branch','Select Printer'));
     } else {
       $data = $donext;
     }
-    if ($data eq 'Issues') {  
-      $donext=Issue($env); #C4::Circulation::Issues 
+    if ($data eq 'Issues') {
+      $donext=Issue($env); #C4::Circulation::Issues
     } elsif ($data eq 'Returns') {
-      $donext=Returns($env); #C4::Circulation::Returns 
+      $donext=Returns($env); #C4::Circulation::Returns
     } elsif ($data eq 'Select Branch') {
       getbranch($env);
     } elsif ($data eq 'Select Printer') {
-      getprinter($env);      
+      getprinter($env);
     } elsif ($data eq 'Borrower Enquiries') {
       #  $donext=Borenq($env); #C4::Circulation::Borrower - conversion
     } elsif ($data eq 'Reserves'){
-      $donext=EnterReserves($env); #C4::Reserves 
-    } elsif ($data eq 'Quit') { 
+      $donext=EnterReserves($env); #C4::Reserves
+    } elsif ($data eq 'Quit') {
       $donext = $data;
     }
   }
-  &endint($env)  
+  &endint($env)
 }
-
-
-END { }       # module clean-up code here (global destructor)
index 5fe47c1..dfa3c0c 100755 (executable)
@@ -1,5 +1,7 @@
 package C4::Database;
 
+# $Id$
+
 # Copyright 2000-2002 Katipo Communications
 #
 # This file is part of Koha.
@@ -21,9 +23,9 @@ use strict;
 require Exporter;
 use DBI;
 use vars qw($VERSION @ISA @EXPORT);
-  
+
 $VERSION = 0.01;
-    
+
 @ISA = qw(Exporter);
 @EXPORT = qw( );
 
index 24bdf84..d76ea77 100755 (executable)
@@ -1,5 +1,7 @@
 package C4::Groups;
 
+# $Id$
+
 #package to deal with Returns
 #written 3/11/99 by olwen@katipo.co.nz
 
@@ -39,10 +41,10 @@ use C4::Stats;
 #use C4::Print;
 
 use vars qw($VERSION @ISA @EXPORT);
-  
+
 # set the version for version checking
 $VERSION = 0.01;
-    
+
 @ISA = qw(Exporter);
 @EXPORT = qw(&getgroups &groupmembers);
 
index b0614df..47d306f 100644 (file)
@@ -1,5 +1,6 @@
-package C4::Security; #assumes C4/Security
+package C4::Security;
 
+# $Id$
 
 # Copyright 2000-2002 Katipo Communications
 #
@@ -43,7 +44,7 @@ sub Login {
   my $sth=$dbh->prepare($query);
   $sth->execute;
   while (my $branchrec=$sth->fetchrow_hashref) {
-    my $branchdet = 
+    my $branchdet =
      fmtstr($env,$branchrec->{'branchcode'},"L2")." ".$branchrec->{'branchname'};
     push @branches,$branchdet;
   }
@@ -67,7 +68,7 @@ sub Login {
         $env->{'usercode'} = $username;
         $env->{'branchcode'} = $branch;
       }
-     
+
     } else {
       debug_msg("","not found");
     }
@@ -76,10 +77,7 @@ sub Login {
   }
   &endint();
 }
-  
+
 sub CheckAccess {
   my ($env)=@_;
   }
-    
-END { }       # module clean-up code here (global destructor)
-    
index 64fa0e6..1f98032 100755 (executable)
@@ -1,5 +1,7 @@
 #!/usr/bin/perl
 
+# $Id$
+
 #
 # TODO
 #
@@ -38,7 +40,7 @@ print startmenu('acquisitions');
 
 print << "EOF";
 <FONT SIZE=6><em>Adding a new Biblio</em></FONT><br>
-  
+
 <table bgcolor="#ffcc00" width="80%" cellpadding="5">
 <tr>
 <td><FONT SIZE=5>Section One: Copyright Information </font></td>
index e29d9e9..f212496 100755 (executable)
@@ -1,10 +1,12 @@
 #!/usr/bin/perl
 
+# $Id$
+
 #
 # Modified saas@users.sf.net 12:00 01 April 2001
 # The biblioitemnumber was not correctly initialised
 # The max(barcode) value was broken - koha 'barcode' is a string value!
-# - If left blank, barcode value now defaults to max(biblionumber) 
+# - If left blank, barcode value now defaults to max(biblionumber)
 
 #
 # TODO
@@ -126,14 +128,14 @@ EOF
 <tr valign="center">
 <td><FONT SIZE=5>Help</font></td>
 </tr>
-</table> 
+</table>
 <FONT SIZE=5>Koha stores data in three sections</font>
 <p />
 <h2>Biblio</h2>
 The first section records bibliographic data such as title, author and copyright for a particular work.
 <p />
-<h2>Group</h2>      
-The second records bibliographic data for a particular publication of that work, such as ISBN number, physical description, publisher information, etc      
+<h2>Group</h2>
+The second records bibliographic data for a particular publication of that work, such as ISBN number, physical description, publisher information, etc
 <p />
 <h2>Item</h2>
 The third section holds specific item information, such as the bar code number
index 193c357..5ebb8b7 100755 (executable)
@@ -1,10 +1,12 @@
 #!/usr/bin/perl
 
+# $Id$
+
 #
 # Modified saas@users.sf.net 12:00 01 April 2001
 # The biblioitemnumber was not correctly initialised
 # The max(barcode) value was broken - koha 'barcode' is a string value!
-# - If left blank, barcode value now defaults to max(biblionumber) 
+# - If left blank, barcode value now defaults to max(biblionumber)
 
 #
 # TODO
@@ -345,13 +347,13 @@ EOF
 <input type=hidden name=biblionumber value=$biblionumber>
 <input type=hidden name=biblioitemnumber value=$biblioitemnumber>
 <table>
-<!-- tr><td>BARCODE</td><td><input name=barcode size=10 value=\$maxbarcode --> 
-<tr><td>BARCODE</td><td><input name=barcode size=10 value=$biblionumber> 
+<!-- tr><td>BARCODE</td><td><input name=barcode size=10 value=\$maxbarcode -->
+<tr><td>BARCODE</td><td><input name=barcode size=10 value=$biblionumber>
 Home Branch: <select name=homebranch>
 EOF
-my $branches=getbranches();                                                                                
-       foreach my $key (sort(keys %$branches)) {                                                                  
-           print "<option value=\"$key\">$branches->{$key}->{'branchname'}</option>";                            
+my $branches=getbranches();
+       foreach my $key (sort(keys %$branches)) {
+           print "<option value=\"$key\">$branches->{$key}->{'branchname'}</option>";
        }
 print << "EOF";
        </select></td></tr>
index c8da4cf..9bffa2d 100755 (executable)
@@ -1,5 +1,6 @@
 #!/usr/bin/perl
 
+# $Id$
 
 # Copyright 2000-2002 Katipo Communications
 #
@@ -55,11 +56,11 @@ if (! $biblionumber) {
        ($biblioitemcount, @biblioitems) = &getbiblioitembybiblionumber($biblionumber);
         ($branchcount, @branches)        = &branches;
        ($itemtypecount, @itemtypes)     = &getitemtypes;
-       
+
        for (my $i = 0; $i < $itemtypecount; $i++) {
            $itemtypedescriptions{$itemtypes[$i]->{'itemtype'}} = $itemtypes[$i]->{'description'};
        } # for
-       
+
        for (my $i = 0; $i < $branchcount; $i++) {
            $branchnames{$branches[$i]->{'branchcode'}} = $branches[$i]->{'branchname'};
        } # for
@@ -104,7 +105,7 @@ EOF
 
        for (my $i = 0; $i < $biblioitemcount; $i++) {
            if ($biblioitems[$i]->{'itemtype'} eq "WEB") {
-               
+
                print << "EOF";
 <tr valign="top" bgcolor="#CCCC99">
 <td background="/images/background-mem.gif"><b>$biblioitems[$i]->{'biblioitemnumber'} GROUP - $itemtypedescriptions{$biblioitems[$i]->{'itemtype'}}</b></td>
index 6c43845..d8f3e47 100755 (executable)
@@ -84,7 +84,7 @@ my $menu = $input->param('menu');
 #
 if ($input->param('z3950queue')) {
        AcceptZ3950Queue($dbh,$input);
-} 
+}
 
 if ($input->param('uploadmarc')) {
        AcceptMarcUpload($dbh,$input)
@@ -157,7 +157,7 @@ sub ProcessRecord {
        $record,
        $data,
     );
-       
+
     if ($file=~/Z-(\d+)/) {
        my $id=$1;
        my $resultsid=$input->param('resultsid');
@@ -169,7 +169,7 @@ sub ProcessRecord {
        $sth->execute;
        ($data) = $sth->fetchrow;
     }
-    
+
     my $file=MARC::File::USMARC->indata ($data);
     my $oldkoha;
     # FIXME - This "==" should be "=", right?
@@ -216,7 +216,7 @@ sub ProcessRecord {
     $template->param(numrecord => $numrecord);
     $template->param(file => $data);
     print "Content-Type: text/html\n\n", $template->output;
-}    
+}
 
 # lists all records from the MARC file
 sub ListFileRecords {
@@ -243,13 +243,13 @@ sub ListFileRecords {
     my $record;
     my ($numrecords,$resultsid,$data,$startdate,$enddate);
                # FIXME - there's already a $data a few lines above.
-    
+
     $dbh = C4::Context->dbh;
 
     my $template=gettemplate('marcimport/ListFileRecords.tmpl');
 
     # File can be z3950 search query or uploaded MARC data
-    
+
     # if z3950 results
     if (not $file=~/Z-(\d+)/) {
        # This is a Marc upload
@@ -261,19 +261,19 @@ sub ListFileRecords {
     }
 
     if ($file=~/Z-(\d+)/) {
-       # This is a z3950 search 
+       # This is a z3950 search
        $template->param(IS_Z3950 =>1);
        my $id=$1;              # search query id number
        my $serverstring;
        my $starttimer=time();
-       
+
        $sth=$dbh->prepare("
                select z3950results.numrecords,z3950results.id,z3950results.results,
-                       z3950results.startdate,z3950results.enddate,server 
-               from z3950queue left outer join z3950results 
-                    on z3950queue.id=z3950results.queryid 
+                       z3950results.startdate,z3950results.enddate,server
+               from z3950queue left outer join z3950results
+                    on z3950queue.id=z3950results.queryid
                where z3950queue.id=?
-               order by server  
+               order by server
            ");
        $sth->execute($id);
        if ( $sth->rows ) {
@@ -314,7 +314,7 @@ sub ListFileRecords {
                    $template->param(numrecords => $numrecords);
                    $template->param(previous => $previous);
                    $template->param(next => $next);
-                   my $stj=$dbh->prepare("update z3950results 
+                   my $stj=$dbh->prepare("update z3950results
                        set highestseen=? where id=?");
                    $stj->execute($startrecord+10,$resultsid);
                }
@@ -353,7 +353,7 @@ sub ListFileRecords {
 
        } else {
 #
-# This is an uploaded Marc record   
+# This is an uploaded Marc record
 #
            my @loop = ();
            my $MARCfile = MARC::File::USMARC->indata($data);
@@ -388,8 +388,8 @@ sub ResultRecordLink {
 
 #    $bib=extractmarcfields($record);
 
-    $sth=$dbh->prepare("select * 
-         from biblioitems 
+    $sth=$dbh->prepare("select *
+         from biblioitems
          where (isbn=? and isbn!='')  or (issn=? and issn!='')  or (lccn=? and lccn!='') ");
     $sth->execute($oldkoha->{isbn},$oldkoha->{issn},$oldkoha->{lccn});
     if ($sth->rows) {
@@ -398,7 +398,7 @@ sub ResultRecordLink {
        $donetext="";
     }
     ($oldkoha->{author}) && ($oldkoha->{author}="by $oldkoha->{author}");
-    
+
     $searchfield="";
     foreach $fieldname ( "controlnumber", "lccn", "issn", "isbn") {
        if ( defined $oldkoha->{$fieldname} && $oldkoha->{$fieldname} ) {
@@ -439,7 +439,7 @@ sub z3950menu {
        $elapsed,
        $elapsedtime,
        $resultstatus, $statuscolor,
-       $id, $term, $type, $done, 
+       $id, $term, $type, $done,
        $startdate, $enddate, $servers,
        $record,$bib,$title,
     );
@@ -464,12 +464,12 @@ EOT
 
     # Check queued queries
     $sth=$dbh->prepare("select id,term,type,done,
-               startdate,enddate,servers 
-       from z3950queue 
-       order by id desc 
+               startdate,enddate,servers
+       from z3950queue
+       order by id desc
        limit 20 ");
     $sth->execute;
-    while ( ($id, $term, $type, $done, 
+    while ( ($id, $term, $type, $done,
                $startdate, $enddate, $servers) = $sth->fetchrow) {
        $type=uc($type);
        $term=~s/</&lt;/g;
@@ -478,14 +478,14 @@ EOT
        $title="";
        # See if query produced results
        $sti=$dbh->prepare("select id,server,startdate,enddate,numrecords,results
-               from z3950results 
+               from z3950results
                where queryid=?");
        $sti->execute($id);
        if ($sti->rows) {
            $processing=0;
            $realenddate=0;
            $totalrecords=0;
-           while (my ($r_id,$r_server,$r_startdate,$r_enddate,$r_numrecords,$r_marcdata) 
+           while (my ($r_id,$r_server,$r_startdate,$r_enddate,$r_numrecords,$r_marcdata)
                = $sti->fetchrow) {
                if ($r_enddate==0) {
                    # It hasn't finished yet
@@ -542,8 +542,8 @@ EOT
     # Search input form
     print "<td valign=top width=30%>\n";
 
-    my $sth=$dbh->prepare("select id,name,checked 
-       from z3950servers 
+    my $sth=$dbh->prepare("select id,name,checked
+       from z3950servers
        order by rank");
                # FIXME - There's already a $sth in this function.
     $sth->execute;
@@ -553,7 +553,7 @@ EOT
        $serverlist.="<input type=checkbox name=S-$id $checked> $name<br>\n";
     }
     $serverlist.="<input type=checkbox name=S-MAN> <input name=manualz3950server size=25 value=otherserver:210/DATABASE>\n";
-    
+
     my $rand=rand(1000000000);
 print << "EOF";
     <form action=$ENV{'SCRIPT_NAME'} method=GET>
@@ -566,10 +566,10 @@ print << "EOF";
            <tr><th bgcolor=#bbbbbb colspan=2>Search for MARC records</th></tr>
     <tr><td>Query Term</td><td><input name=query></td></tr>
     <tr><td colspan=2 align=center>
-               <input type=radio name=type value=isbn checked>&nbsp;ISBN 
+               <input type=radio name=type value=isbn checked>&nbsp;ISBN
                <input type=radio name=type value=lccn        >&nbsp;LCCN<br>
-               <input type=radio name=type value=author      >&nbsp;Author 
-               <input type=radio name=type value=title       >&nbsp;Title 
+               <input type=radio name=type value=author      >&nbsp;Author
+               <input type=radio name=type value=title       >&nbsp;Title
                <input type=radio name=type value=keyword     >&nbsp;Keyword</td></tr>
             <tr><td colspan=2> $serverlist </td></tr>
             <tr><td colspan=2 align=center> <input type=submit> </td></tr>
@@ -652,7 +652,7 @@ sub AcceptZ3950Queue {
           }
         }
 
-       $error=addz3950queue($dbh,$input->param('query'), $input->param('type'), 
+       $error=addz3950queue($dbh,$input->param('query'), $input->param('type'),
                $input->param('rand'), @serverlist);
        if ( $error ) {
            print qq|
@@ -669,7 +669,7 @@ script should be run as root, and it will start up the program running with the<
 privileges of your apache user.  Ideally, this script should be started from a<br>
 system init directory so that is running after the machine starts up.
 |;
-       
+
            } # if daemon
            print qq|
 </td></tr>
@@ -708,8 +708,8 @@ sub AcceptMarcUpload {
     }
     my $q_marcrecord=$dbh->quote($marcrecord);
     my $q_name=$dbh->quote($name);
-    my $sth=$dbh->prepare("insert into uploadedmarc 
-               (marc,name) 
+    my $sth=$dbh->prepare("insert into uploadedmarc
+               (marc,name)
        values ($q_marcrecord, $q_name)");
     $sth->execute;
 } # sub AcceptMarcUpload
@@ -757,8 +757,8 @@ sub AcceptBiblioitem {
     my $oldkoha = MARCmarc2koha($dbh,$record);
     # See if it already exists
     # FIXME - There's already a $sth in this context.
-    my $sth=$dbh->prepare("select biblionumber,biblioitemnumber 
-       from biblioitems 
+    my $sth=$dbh->prepare("select biblionumber,biblioitemnumber
+       from biblioitems
        where isbn=? or issn=? or lccn=?");
     $sth->execute($oldkoha->{isbn},$oldkoha->{issn},$oldkoha->{lccn});
     if ($sth->rows) {
@@ -776,14 +776,14 @@ sub AcceptBiblioitem {
        my $error;
        my %biblio;
        my %biblioitem;
-  
+
        # convert to upper case and split on lines
        my $subjectheadings=$input->param('subject');
        my @subjectheadings=split(/[\r\n]+/,$subjectheadings);
-  
+
        my $additionalauthors=$input->param('additionalauthors');
        my @additionalauthors=split(/[\r\n]+|\|/,uc($additionalauthors));
-  
+
        # Use individual assignments to hash buckets, in case
        #  any of the input parameters are empty or don't exist
        $biblio{title}          =$input->param('title');
@@ -793,7 +793,7 @@ sub AcceptBiblioitem {
        $biblio{notes}          =$input->param('notes');
        $biblio{abstract}       =$input->param('abstract');
        $biblio{subtitle}       =$input->param('subtitle');
-  
+
        $biblioitem{volume}             =$input->param('volume');
        $biblioitem{number}             =$input->param('number');
        $biblioitem{itemtype}           =$input->param('itemtype');
@@ -823,10 +823,10 @@ sub AcceptBiblioitem {
 #              \@subjectheadings,
 #              \@additionalauthors
 #      );
-  
+
        if ( $error ) {
            print "<H2>Error adding biblio item</H2> $error\n";
-       } else { 
+       } else {
            $template->param(title => $title);
            $template->param(biblionumber => $biblionumber);
            $template->param(biblioitemnumber => $biblioitemnumber);
@@ -867,8 +867,8 @@ sub AcceptItemCopy {
     my $barcode=$input->param('barcode');
     my $replacementprice=($input->param('replacementprice') || 0);
 
-    my $sth=$dbh->prepare("select barcode 
-       from items 
+    my $sth=$dbh->prepare("select barcode
+       from items
        where barcode=?");
     $sth->execute($barcode);
     if ($sth->rows) {
@@ -998,6 +998,10 @@ sub FormatMarcText {
 
 #---------------
 # $Log$
+# Revision 1.17  2002/10/13 07:39:26  arensb
+# Added magic RCS comment.
+# Removed trailing whitespace.
+#
 # Revision 1.16  2002/10/11 12:45:10  arensb
 # Replaced &requireDBI with C4::Context->dbh, thus making the "use
 # Fixed muffed quotes in &gettemplate calls.
index 20e899b..bb64540 100755 (executable)
@@ -1,4 +1,7 @@
 #!/usr/bin/perl
+
+# $Id$
+
 use C4::Context;
 use DBI;
 #use strict;
@@ -9,22 +12,22 @@ use Net::Z3950;
 
 
 if ($< == 0) {
-    # Running as root, switch privs 
+    # Running as root, switch privs
     if (-d "/var/run") {
        open PID, ">/var/run/processz3950queue.pid";
        print PID $$."\n";
        close PID;
     }
     # Get real apacheuser from koha.conf or reparsing httpd.conf
-    my $apacheuser='www-data';  
+    my $apacheuser='www-data';
     my $uid=0;
-    unless ($uid = (getpwnam($apacheuser))[2]) { 
+    unless ($uid = (getpwnam($apacheuser))[2]) {
        die "Attempt to run daemon as non-existent or superuser\n";
     }
     $>=$uid;
     $<=$uid;
 }
-    
+
 
 my $dbh = C4::Context->dbh;
 
index 491cb97..2726f09 100755 (executable)
@@ -1,5 +1,6 @@
 #!/usr/bin/perl
 
+# $Id$
 
 # Copyright 2000-2002 Katipo Communications
 #
@@ -75,7 +76,7 @@ if (! $biblionumber) {
 } elsif ((! $newgroup) && (! $biblioitemnumber)) {
     print $input->redirect("additem.pl?biblionumber=$biblionumber&error=nobiblioitem");
 } else {
-    
+
     if ($website) {
        &newbiblioitem($biblioitem);
     } elsif (&checkitems(1,$barcode)) {
index 53cc6c6..969f497 100755 (executable)
@@ -1,5 +1,7 @@
 #!/usr/bin/perl
 
+# $Id$
+
 #script to recieve orders
 #written by chris@katipo.co.nz 24/2/2000
 
@@ -44,7 +46,7 @@ my $biblio=$input->param('biblio');
 my $catview=$input->param('catview');
 my $gst=$input->param('gst');
 my ($count,@results)=ordersearch($search,$biblio,$catview);
-my ($count2,@booksellers)=bookseller($results[0]->{'booksellerid'}); 
+my ($count2,@booksellers)=bookseller($results[0]->{'booksellerid'});
 #print $count;
 my @date=split('-',$results[0]->{'entrydate'});
 my $date="$date[2]/$date[1]/$date[0]";
@@ -151,14 +153,14 @@ print <<EOP
 <td><select name=branch size=1>
 EOP
 ;
-my ($count2,@branches)=branches();                                                                         
-for (my $i=0;$i<$count2;$i++){                                                                           
-  print "<option value=$branches[$i]->{'branchcode'}";                                                   
-  if ($results[0]->{'branchcode'} == $branches[$i]->{'branchcode'}){                                           
-  print " Selected";                                                                                   
-  }                                                                                                      
-  print ">$branches[$i]->{'branchname'}";                                                                
-}   
+my ($count2,@branches)=branches();
+for (my $i=0;$i<$count2;$i++){
+  print "<option value=$branches[$i]->{'branchcode'}";
+  if ($results[0]->{'branchcode'} == $branches[$i]->{'branchcode'}){
+  print " Selected";
+  }
+  print ">$branches[$i]->{'branchname'}";
+}
 print <<EOP
 </select>
 </td>
@@ -210,14 +212,14 @@ print <<EOP
 EOP
 ;
 my @bookfund;
-($count2,@bookfund)=bookfunds();                                                    
-for (my $i=0;$i<$count2;$i++){                                                       
+($count2,@bookfund)=bookfunds();
+for (my $i=0;$i<$count2;$i++){
   print "<option value=$bookfund[$i]->{'bookfundid'}";
   if ($bookfund[$i]->{'bookfundid'}==$results[0]->{'bookfundid'}){
     print " Selected";
   }
   print ">$bookfund[$i]->{'bookfundname'}";
-}      
+}
 
 my $rrp=$results[0]->{'rrp'};
 if ($results[0]->{'quantityreceived'} == 0){
@@ -269,7 +271,7 @@ Budgeted Cost </td>
 </table>
 </form>
 </center>
-<br clear=all>         
+<br clear=all>
 <p> &nbsp; </p>
 
 EOP
@@ -277,11 +279,11 @@ EOP
 } else {
 print "<center><table>";
 print <<EOP
-<tr valign=top bgcolor=#99cc33>                                                                
+<tr valign=top bgcolor=#99cc33>
 
-<td background="/images/background-mem.gif"><b>ISBN</b></td>                                   
-<td background="/images/background-mem.gif"><b>TITLE</b></td>                                  
-<td background="/images/background-mem.gif"><b>AUTHOR</b></td>                                 
+<td background="/images/background-mem.gif"><b>ISBN</b></td>
+<td background="/images/background-mem.gif"><b>TITLE</b></td>
+<td background="/images/background-mem.gif"><b>AUTHOR</b></td>
 </tr>
 EOP
 ;
index 03b9b9f..d5502f7 100755 (executable)
@@ -1,5 +1,7 @@
 #!/usr/bin/perl
 
+# $Id$
+
 #script to show display basket of orders
 #written by chris@katipo.co.nz 24/2/2000
 
@@ -49,7 +51,7 @@ Our Reference: $basket<br>
 Authorised By: $results[0]->{'authorisedby'}<br>
 $results[0]->{'entrydate'};
 </div>
-<FONT SIZE=6><em>Shopping Basket For: <a href=supplier.pl?id=$results[0]->{'booksellerid'}></a> $booksellers[0]->{'name'}</em></FONT>  
+<FONT SIZE=6><em>Shopping Basket For: <a href=supplier.pl?id=$results[0]->{'booksellerid'}></a> $booksellers[0]->{'name'}</em></FONT>
 <a href=newbasket.pl?id=$results[0]->{'booksellerid'}&basket=$basket>Add more orders</a>
 <CENTER>
 <FORM ACTION="/cgi-bin/koha/search.pl" method=post>
@@ -87,7 +89,7 @@ $sub_total+=$line_total;
 $gist=sprintf("%.2f",$sub_total*0.125);
 $grand_total=$sub_total+$gist;
 
-print <<EOP      
+print <<EOP
 <tr valign=top bgcolor=#ffffcc>
   <td>$results[$i]->{'ordernumber'}</td>
   <td>$results[$i]->{'isbn'}</td>
@@ -98,12 +100,12 @@ print <<EOP
   <td><input type=text name=quantity$i size=6 value=$results[$i]->{'quantity'} onchange='update(this.form)'></td>
   <td>\$<input type=text name=total$i size=10 value=$line_total></td>
   <input type=hidden name=ordnum$i value=$results[$i]->{'ordernumber'}>
-  <input type=hidden name=bibnum$i value=$results[$i]->{'biblionumber'}> 
+  <input type=hidden name=bibnum$i value=$results[$i]->{'biblionumber'}>
 </tr>
 EOP
 ;
 }
-# 
+#
 print "<input type=hidden name=number value=$count>
 <input type=hidden name=basketno value=\"$basket\">";
 print <<EOP
@@ -111,7 +113,7 @@ print <<EOP
   <b>HELP</b><br>
   To cancel an order, just change the quantity to 0 and click "save changes".<br>
   To change any of the catalogue or accounting information attached to an order,  click on the title.<br>
-  To add new orders to this supplier, start with a search. </td> 
+  To add new orders to this supplier, start with a search. </td>
   <td><b>SubTotal</b></td>
   <td>\$<input type=text name=subtotal size=10 value=$sub_total></td></tr>
 <tr valign=top bgcolor=white>
@@ -128,7 +130,7 @@ print <<EOP
   <td></td>
   <td colspan=3><input type=image  name=submit src=/images/save-changes.gif border=0 width=187 height=42 align=right></td></tr>
 </table>
-</CENTER>  
+</CENTER>
 EOP
   ;
 
index f6705c6..f4ccdda 100755 (executable)
@@ -1,5 +1,7 @@
 #!/usr/bin/perl
 
+# $Id$
+
 #script to show display basket of orders
 #written by chris@katipo.co.nz 24/2/2000
 
@@ -52,7 +54,7 @@ $date
 <FONT SIZE=6><em>Shopping Basket For: <a href=/cgi-bin/koha/acqui/supplier.pl?id=$booksellers[0]->{'id'}>
 $booksellers[0]->{'name'}</a></em></FONT><br>
 Ph: $booksellers[0]->{'phone'}, Fax: $booksellers[0]->{'fax'},
-$booksellers[0]->{'address1'}, $booksellers[0]->{'address2'}, 
+$booksellers[0]->{'address1'}, $booksellers[0]->{'address2'},
 $booksellers[0]->{'address3'}, $booksellers[0]->{'address4'}
 
 
@@ -60,7 +62,7 @@ $booksellers[0]->{'address3'}, $booksellers[0]->{'address4'}
 <FORM ACTION="/cgi-bin/koha/acqui/newbasket2.pl" method=post>
 <input type=hidden name=id value="$id">
 <input type=hidden name=basket value="$basket">
-<b> Search Keyword or Title: </b><INPUT TYPE="text"  SIZE="25"   NAME="search"> 
+<b> Search Keyword or Title: </b><INPUT TYPE="text"  SIZE="25"   NAME="search">
 
 </form>
 
index 2fbfccc..6766966 100755 (executable)
@@ -1,5 +1,7 @@
 #!/usr/bin/perl
 
+# $Id$
+
 #script to show suppliers and orders
 #written by chris@katipo.co.nz 23/2/2000
 
@@ -64,7 +66,7 @@ for (my $i=0; $i<$count; $i++) {
     if ($orders->[0]->{'basketno'}>0) {
        print <<printend
            <tr valign=top bgcolor=$colour>
-           <td><a href="newbasket.pl?id=$suppliers[$i]->{'id'}"><img src="/images/new-basket-short.gif" alt="New Basket" width=77 height=32 border=0 ></a> 
+           <td><a href="newbasket.pl?id=$suppliers[$i]->{'id'}"><img src="/images/new-basket-short.gif" alt="New Basket" width=77 height=32 border=0 ></a>
            <a href="recieveorder.pl?id=$suppliers[$i]->{'id'}"><img src="/images/receive-order-short.gif" alt="Receive Order" width=77 height=32 border=0 ></a></td>
            <td><a href="supplier.pl?id=$suppliers[$i]->{'id'}">$suppliers[$i]->{'name'}</a></td>
            <td><a href="/cgi-bin/koha/acqui/basket.pl?basket=$orders->[0]->{'basketno'}">HLT-$orders->[0]->{'basketno'}</a></td>
@@ -76,7 +78,7 @@ printend
     } else {
        print <<printend
            <tr valign=top bgcolor=$colour>
-           <td><a href="newbasket.pl?id=$suppliers[$i]->{'id'}"><img src="/images/new-basket-short.gif" alt="New Basket" width=77 height=32 border=0 ></a> 
+           <td><a href="newbasket.pl?id=$suppliers[$i]->{'id'}"><img src="/images/new-basket-short.gif" alt="New Basket" width=77 height=32 border=0 ></a>
            <a href="recieveorder.pl?id=$suppliers[$i]->{'id'}"><img src="/images/receive-order-short.gif" alt="Receive Order" width=77 height=32 border=0 ></a></td>
            <td><a href="supplier.pl?id=$suppliers[$i]->{'id'}">$suppliers[$i]->{'name'}</a></td>
            <td>&nbsp;</a></td>
@@ -95,7 +97,7 @@ printend
                <td><a href="/cgi-bin/koha/acqui/basket.pl?basket=$orders->[$i2]->{'basketno'}">HLT-$orders->[$i2]->{'basketno'}</a></td>
                <td>$orders->[$i2]->{'count(*)'}</td><td>$orders->[$i2]->{'authorisedby'} &nbsp; </td>
                <td>$orders->[$i2]->{'entrydate'}</td></tr>
-               
+
 printend
 ;
        } else {
@@ -106,7 +108,7 @@ printend
                <td> &nbsp;</td>
                <td>$orders->[$i2]->{'count(*)'}</td><td>$orders->[$i2]->{'authorisedby'} &nbsp; </td>
                <td>$orders->[$i2]->{'entrydate'}</td></tr>
-               
+
 printend
 ;
        }
index bbda54f..3b33909 100755 (executable)
@@ -1,5 +1,7 @@
 #!/usr/bin/perl
 
+# $Id$
+
 #script to recieve orders
 #written by chris@katipo.co.nz 24/2/2000
 
@@ -132,7 +134,7 @@ print <<EOP
 <br>
 The total at the bottom of the page should be within a few cents of the total for the invoice.<p>
 When you have finished this invoice save the changes.
-</td>                                                                                                                                                                                                                                          
+</td>
 <td colspan=2 align=right><b>GST</b></td>
 <td>\$$gst</td>
 </tr>
index e7ae3b0..1351ecb 100755 (executable)
@@ -1,5 +1,7 @@
 #!/usr/bin/perl
 
+# $Id$
+
 #script to show display basket of orders
 #written by chris@katipo.co.nz 24/2/2000
 
@@ -30,7 +32,7 @@ use strict;
 my $input=new CGI;
 print $input->header();
 my $id=$input->param('id');
-my ($count,@booksellers)=bookseller($id); 
+my ($count,@booksellers)=bookseller($id);
 print startpage;
 
 print startmenu('acquisitions');
@@ -47,7 +49,7 @@ print <<EOP
 <tr valign=top bgcolor=#99cc33><td background="/images/background-mem.gif" colspan=2><B>SUPPLIER INVOICE INFORMATION</B></td></tr>
 <TR VALIGN=TOP >
 <TD>Supplier Invoice Number</td>
-<td><input type=text size=20 name=invoice>        
+<td><input type=text size=20 name=invoice>
 </td>
 </tr>
 <TR VALIGN=TOP>
index 2262adc..cb3ff66 100755 (executable)
@@ -1,5 +1,7 @@
 #!/usr/bin/perl
 
+# $Id$
+
 #script to show display basket of orders
 #written by chris@katipo.co.nz 24/2/2000
 
@@ -30,7 +32,7 @@ use strict;
 my $input=new CGI;
 print $input->header();
 my $id=$input->param('id');
-my ($count,@booksellers)=bookseller($id); 
+my ($count,@booksellers)=bookseller($id);
 print startpage;
 
 print startmenu('acquisitions');
@@ -210,7 +212,7 @@ EOP
 if ($booksellers[0]->{'gstreg'}==1){
   print " checked";
 }
-print ">Yes 
+print ">Yes
 <input type=radio name=gst value=0";
 if ($booksellers[0]->{'gstreg'}==0){
   print " checked";
@@ -227,7 +229,7 @@ EOP
 if ($booksellers[0]->{'listincgst'}==1){
   print " checked";
 }
-print ">Yes 
+print ">Yes
 <input type=radio name=list_gst value=0";
 if ($booksellers[0]->{'listincgst'}==0){
   print " checked";
@@ -244,7 +246,7 @@ EOP
 if ($booksellers[0]->{'invoiceincgst'}==1){
   print " checked";
 }
-print ">Yes 
+print ">Yes
 <input type=radio name=invoice_gst value=0";
 if ($booksellers[0]->{'invoiceincgst'}==0){
   print " checked";
@@ -253,7 +255,7 @@ print <<EOP
 >No
 </td>
 </tr>
-<TR VALIGN=TOP>                                
+<TR VALIGN=TOP>
 <TD>Discount</td>
 <td><input type=text size=3 name=discount value=$booksellers[0]->{'discount'}> %
 </tr>
index ccb47d7..cc563a0 100755 (executable)
@@ -1,5 +1,7 @@
 #!/usr/bin/perl
 
+# $Id$
+
 #written 7/3/2002 by Finlay
 #script to display reports
 
@@ -58,7 +60,7 @@ if (not $lastmove) {
 }
 
 
-# make the page ... 
+# make the page ...
 print $input->header;
 
 
@@ -133,7 +135,7 @@ sub lastmove {
       $sth->execute;
       my ($date) = $sth->fetchrow_array;
       return(0, "Item has no branch transfers record") if not $date;
-      my $var2 = $dbh->quote($date);      
+      my $var2 = $dbh->quote($date);
       $sth=$dbh->prepare("Select * from branchtransfers where branchtransfers.itemnumber=$var1 and branchtransfers.datearrived=$var2");
       $sth->execute;
       my ($data) = $sth->fetchrow_hashref;
index 704f412..e1ec28e 100755 (executable)
@@ -1,5 +1,7 @@
 #!/usr/bin/perl
 
+# $Id$
+
 #writen 11/1/2000 by chris@katipo.oc.nz
 #script to display borrowers account details
 
@@ -39,8 +41,8 @@ my $data=borrdata('',$bornum);
 
 #get account details
 my %bor;
-$bor{'borrowernumber'}=$bornum;                            
-my ($numaccts,$accts,$total)=getboracctrecord('',\%bor);   
+$bor{'borrowernumber'}=$bornum;
+my ($numaccts,$accts,$total)=getboracctrecord('',\%bor);
 
 my @accountrows; # this is for the tmpl-loop
 
@@ -66,6 +68,6 @@ $template->param( startmenumember => startmenu('member'),
                        surname         => $data->{'surname'},
                        bornum          => $bornum,
                        total           => $total,
-                       accounts        => \@accountrows ); 
+                       accounts        => \@accountrows );
 
-print "Content-Type: text/html\n\n", $template->output;
\ No newline at end of file
+print "Content-Type: text/html\n\n", $template->output;
index fabc1fe..1ff2f65 100755 (executable)
@@ -1,5 +1,7 @@
 #!/usr/bin/perl
 
+# $Id$
+
 #written by chris@katipo.co.nz
 #9/10/2000
 #script to display and update currency rates
@@ -40,7 +42,7 @@ if ($type ne 'change'){
   <input type=hidden name=type value=change>
   <TR VALIGN=TOP>
   <TD  bgcolor="99cc33" background="/images/background-mem.gif" colspan=2 ><b>EXCHANGE RATES </b></TD></TR>
-  <TR VALIGN=TOP>                                                                 
+  <TR VALIGN=TOP>
   <TD>
 printend
 ;
@@ -52,12 +54,12 @@ printend
 #    print $rates->[$i]->{'currency'};
   }
   print <<printend
-    <p>                                                                             
+    <p>
   <input type=image  name=submit src=/images/save-changes.gif border=0 width=187 height=42>
-  
-  </TD></TR>                                                                      
-  </form>                                                                         
-  </table>                                                
+
+  </TD></TR>
+  </form>
+  </table>
 printend
 ;
 } else {
index f2260ca..ae60e86 100755 (executable)
@@ -1,5 +1,7 @@
 #!/usr/bin/perl
 
+# $Id$
+
 #script to delete items
 #written 2/5/00
 #by chris@katipo.co.nz
@@ -50,9 +52,9 @@ my $sth=$dbh->prepare($query);
 $sth->execute;
 my $data=$sth->fetchrow_hashref;
 $sth->finish;
-      
 
-if ($i > 0 || $flags->{'CHARGES'} ne '' || $data ne ''){ 
+
+if ($i > 0 || $flags->{'CHARGES'} ne '' || $data ne ''){
   print $input->header;
   print "<table border=1>";
   if ($i > 0){
index 3a7dc63..ab0657c 100755 (executable)
--- a/groups.pl
+++ b/groups.pl
@@ -1,5 +1,7 @@
 #!/usr/bin/perl
 
+# $Id$
+
 #written 14/1/2000
 #script to display reports
 
@@ -132,7 +134,7 @@ EOF
 </tr></table>
 </td></tr></table>
 <p>
-Printer: 
+Printer:
 <select name=printer>
 $printeroptions
 </select>
index a8e0bef..63c0923 100644 (file)
@@ -1,5 +1,6 @@
 #!/usr/bin/perl -w # please develop with -w
 
+# $Id$
 
 # Copyright 2000-2002 Katipo Communications
 #
@@ -28,16 +29,16 @@ print qq|
 *******************************************
 
 This installer will guide you through the process of installing Koha.
-It is not a completely automated installation, but a guide for further 
+It is not a completely automated installation, but a guide for further
 information please read the documentation or visit the Koha website at
 http://www.koha.org
 
 To successfully use Koha you need some additional software:
 
 * A webserver (It was built to work with Apache, but there is no reason
-it should not work with any other webserver). 
-* Mysql (You could intead use postgres, or another sql based database) 
+it should not work with any other webserver).
+
+* Mysql (You could intead use postgres, or another sql based database)
 
 * Perl
 
@@ -98,10 +99,10 @@ print "\n";
 #
 print qq|
 Koha uses a small configuration file that is usually placed in your
-/etc/ files directory (note: if you wish to place the koha.conf in 
+/etc/ files directory (note: if you wish to place the koha.conf in
 another location you will need to manually edit additional files).
 
-We will help you to now create your koha.conf file, once this file 
+We will help you to now create your koha.conf file, once this file
 has been created, please copy it to your destination folder
 (note: this may need to be done by your systems administrator).
 |;
@@ -115,7 +116,7 @@ my $inc_path;
 print "\n";
 print "\n";
 print qq|
-Please provide the name of the mysql database that you wish to use 
+Please provide the name of the mysql database that you wish to use
 for koha. This is normally "Koha".
 |;
 
@@ -129,7 +130,7 @@ do {
 print "\n";
 print "\n";
 print qq|
-Please provide the hostname for mysql.  Unless the database is located 
+Please provide the hostname for mysql.  Unless the database is located
 on another machine this is likely to be "localhost".
 |;
 
@@ -143,7 +144,7 @@ do {
 print "\n";
 print "\n";
 print qq|
-Please provide the name of the mysql user, who will have full administrative 
+Please provide the name of the mysql user, who will have full administrative
 rights to the $dbname database, when authenicating from $hostname.
 It is recommended that you do not use your "root" user.
 |;
@@ -182,7 +183,7 @@ do {
 
 
 #Create the configuration file
-open(SITES,">koha.conf") or die "Couldn't create file.  
+open(SITES,">koha.conf") or die "Couldn't create file.
 Must have write capability.\n";
 print SITES <<EOP
 database=$dbname
@@ -243,7 +244,7 @@ do {
 #
 # Update Apache Conf File.
 #
-open(SITES,">>koha-apache.conf") or die "Couldn't write to file.  
+open(SITES,">>koha-apache.conf") or die "Couldn't write to file.
 Must have write capability.\n";
 print SITES <<EOP
 
@@ -293,7 +294,7 @@ do {
 #
 # Update Apache Conf File.
 #
-open(SITES,">>koha-apache.conf") or die "Couldn't write to file.  
+open(SITES,">>koha-apache.conf") or die "Couldn't write to file.
 Must have write capability.\n";
 print SITES <<EOP
 
@@ -318,19 +319,19 @@ print qq|
 * Koha Installation Guide - Continued     *
 *******************************************
 
-In order to finish the installation of Koha, there is still a couple 
+In order to finish the installation of Koha, there is still a couple
 of steps that you will need to complete.
 
   * Setup mysql
        1. Create a new mysql database called for example Koha
-          From command line: mysqladmin -uroot -ppassword create Koha 
+          From command line: mysqladmin -uroot -ppassword create Koha
 
        2. Set up a koha user and password in mysql
-           Log in to mysql: mysql -uroot -ppassword 
+           Log in to mysql: mysql -uroot -ppassword
 
-          To create a user called "koha" who has full administrative 
-          rights to the "Koha" database when authenticating from 
-          "localhost", enter the following on mysql command line: 
+          To create a user called "koha" who has full administrative
+          rights to the "Koha" database when authenticating from
+          "localhost", enter the following on mysql command line:
 
            grant all privileges on Koha.* to koha\@localhost identified by 'kohapassword'\;
 
@@ -338,10 +339,10 @@ of steps that you will need to complete.
 
 
        3. Use the mysql script to create the tables
-          mysql -uusername -ppassword Koha < koha.mysql 
+          mysql -uusername -ppassword Koha < koha.mysql
 
        4. Update your database tables
-          perl updatedatabase -I /pathtoC4 
+          perl updatedatabase -I /pathtoC4
 
        5. Update your database to use MARC
           perl marc/fill_usmarc.pl -I /pathtoC4 to put MARC21 - english datas in parameter table
@@ -349,7 +350,7 @@ of steps that you will need to complete.
 
   * Koha.conf
        1. Copy Koha.conf to /etc/
-          If you wish to locate the file in another location please read 
+          If you wish to locate the file in another location please read
           the INSTALL and Hints files.
 
 
index 6fafab6..a70b16f 100644 (file)
@@ -1,5 +1,7 @@
 #!/usr/bin/perl -w # please develop with -w
 
+# $Id$
+
 #use diagnostics;
 
 # Copyright 2000-2002 Katipo Communications
@@ -102,7 +104,7 @@ basic information about your desired setup, then install Koha according to
 your specifications.  To accept the default value for any question, simply hit
 Enter at the prompt.
 
-Please be sure to read the documentation, or visit the Koha website at 
+Please be sure to read the documentation, or visit the Koha website at
 http://www.koha.org for more information.
 
 Are you ready to begin the installation? (Y/[N]):
@@ -115,10 +117,10 @@ if ($answer eq "Y" || $answer eq "y") {
        print "Great! continuing setup... \n";
     } else {
     print qq|
-This installer currently does not support a completely automated 
+This installer currently does not support a completely automated
 setup.
 
-Please be sure to read the documentation, or visit the Koha website 
+Please be sure to read the documentation, or visit the Koha website
 at http://www.koha.org for more information.
 |;
     exit;
@@ -145,7 +147,7 @@ my @missing = ();
 unless (eval {require DBI})               { push @missing,"DBI" };
 unless (eval {require Date::Manip})       { push @missing,"Date::Manip" };
 unless (eval {require DBD::mysql})        { push @missing,"DBD::mysql" };
-unless (eval {require Net::Z3950})        { 
+unless (eval {require Net::Z3950})        {
     print qq|
 
 The Net::Z3950 module is missing.  This module is necessary if you want to use
@@ -209,8 +211,8 @@ Usually $opacdir
 
 INTRANET/LIBRARIANS DIRECTORY
 =============================
-Please supply the directory you want Koha to store its Intranet/Librarians files 
-in.  Leave off the trailing slash.  This directory will be auto-created for you if 
+Please supply the directory you want Koha to store its Intranet/Librarians files
+in.  Leave off the trailing slash.  This directory will be auto-created for you if
 it doesn't exist.
 
 |;
@@ -278,7 +280,7 @@ if ($input) {
 #Get the hostname for the database
 print qq|
 
-Please provide the hostname for mysql.  Unless the database is located on another 
+Please provide the hostname for mysql.  Unless the database is located on another
 machine this will be "localhost".
 |;
 
@@ -650,7 +652,7 @@ if ($input) {
 }
 
 unless (-e "$kohalogdir") {
-    my $result = mkdir 0770, "$kohalogdir"; 
+    my $result = mkdir 0770, "$kohalogdir";
     if ($result==0) {
         my @dirs = split(m#/#, $kohalogdir);
        my $checkdir='';
@@ -800,7 +802,7 @@ if (!$mysqldir){
     $mysqldir='/usr';
 }
 print qq|
-To allow us to create the koha database please supply the 
+To allow us to create the koha database please supply the
 mysql\'s root users password
 |;
 
@@ -999,7 +1001,7 @@ and the OPAC interface at :
    http://$servername\:$opacport/
 
 
-Be sure to read the INSTALL, and Hints files. 
+Be sure to read the INSTALL, and Hints files.
 
 For more information visit http://www.koha.org
 
index 8f207a4..2edfe05 100644 (file)
@@ -1,5 +1,7 @@
 #!/usr/bin/perl -w
 
+# $Id$
+
 #use diagnostics;
 use strict; # please develop with the strict pragma
 
@@ -85,7 +87,7 @@ You are attempting to upgrade from Koha $kohaversion to $newversion.
 We recommend that you do a complete backup of all your files before upgrading.
 This upgrade script will make a backup copy of your files for you.
 
-Would you like to proceed?  ([Y]/N):  
+Would you like to proceed?  ([Y]/N):
 |;
 
 my $answer = <STDIN>;
@@ -121,7 +123,7 @@ my @missing = ();
 unless (eval {require DBI})               { push @missing,"DBI" };
 unless (eval {require Date::Manip})       { push @missing,"Date::Manip" };
 unless (eval {require DBD::mysql})        { push @missing,"DBD::mysql" };
-unless (eval {require Net::Z3950})        { 
+unless (eval {require Net::Z3950})        {
     print qq|
 
 The Net::Z3950 module is missing.  This module is necessary if you want to use
@@ -154,7 +156,7 @@ if (@missing > 0) {
 
 
 my $backupdir='/usr/local/koha/backups';
-print "Please specify a backup directory [$backupdir]: ";  
+print "Please specify a backup directory [$backupdir]: ";
 
 $answer = <STDIN>;
 chomp $answer;
@@ -285,7 +287,7 @@ if (!$opacdir || !$intranetdir) {
     $intranetdir='';
     $opacdir='';
     while (!$intranetdir) {
-       print "Please specify the location of your INTRANET files: ";  
+       print "Please specify the location of your INTRANET files: ";
 
        $answer = <STDIN>;
        chomp $answer;
@@ -299,7 +301,7 @@ if (!$opacdir || !$intranetdir) {
        }
     }
     while (!$opacdir) {
-       print "Please specify the location of your OPAC files: ";  
+       print "Please specify the location of your OPAC files: ";
 
        $answer = <STDIN>;
        chomp $answer;
@@ -440,7 +442,7 @@ unless ($kohalogdir && -e $kohalogdir) {
 }
 
 unless (-e "$kohalogdir") {
-    my $result = mkdir 0770, "$kohalogdir"; 
+    my $result = mkdir 0770, "$kohalogdir";
     if ($result==0) {
         my @dirs = split(m#/#, $kohalogdir);
        my $checkdir='';
index f042763..6a84456 100755 (executable)
--- a/member.pl
+++ b/member.pl
@@ -1,5 +1,7 @@
 #!/usr/bin/perl
 
+# $Id$
+
 #script to do a borrower enquiery/brin up borrower details etc
 #written 20/12/99 by chris@katipo.co.nz
 
@@ -33,7 +35,7 @@ my $theme = $input->param('theme') || "default";
                        # only used if allowthemeoverride is set
 my %tmpldata = pathtotemplate ( template => 'member.tmpl', theme => $theme, language => 'fi' );
        # FIXME - Error-checking
-my $template = HTML::Template->new( filename => $tmpldata{'path'}, 
+my $template = HTML::Template->new( filename => $tmpldata{'path'},
                                    die_on_bad_params => 0,
                                    loop_context_vars => 1 );
 
@@ -66,5 +68,5 @@ $template->param( startmenumember => join ('', startmenu('member')),
                        endmenumember   => join ('', endmenu('member')),
                        member          => $member,
                        resultsloop     => \@resultsdata );
-                       
+
 print "Content-Type: text/html\n\n", $template->output;
index 39321ac..ec95459 100755 (executable)
@@ -1,5 +1,7 @@
 #!/usr/bin/perl
 
+# $Id$
+
 #script to set up screen for modification of borrower details
 #written 20/12/99 by chris@katipo.co.nz
 
@@ -40,7 +42,7 @@ if ($member eq ''){
   $member=NewBorrowerNumber();
 }
 my $type=$input->param('type') || '';
-my $modify=$input->param('modify.x'); 
+my $modify=$input->param('modify.x');
 my $delete=$input->param('delete.x');
 if ($delete){
   print $input->redirect("/cgi-bin/koha/deletemem.pl?member=$member");
@@ -51,15 +53,15 @@ if ($delete){
   } else {
     $template->param( header => 'Add New Member');
   }
-  
+
   my $data=borrdata('',$member);
-  
+
   if ($type eq 'Add'){
     $template->param( updtype => 'I');
   } else {
     $template->param( updtype => 'M');
   }
-  
+
   my $cardnumber=$data->{'cardnumber'};
   my $autonumber_members = C4::Context->preference("autoMemberNum") || 0;
                # Find out whether member numbers should be generated
@@ -88,7 +90,7 @@ if ($delete){
     } else {
       $cardnumber = $cardnumber + 1;           # FIXME - $cardnumber++;
     }
-  
+
     while ($i <8) {                    # step from char 1 to 7.
       my $temp1 = $weightings[$i];     # read weightings, left to right, 1 char at a time
       my $temp2 = substr($cardnumber,$i,1);    # sequence left to right, 1 char at a time
@@ -100,16 +102,16 @@ if ($delete){
     my $rem = ($sum%11);                       # remainder of sum/11 (eg. 9999999/11, remainder=2)
     if ($rem == 10) {                  # if remainder is 10, use X instead
       $rem = "X";
-    }  
+    }
     $cardnumber="V$cardnumber$rem";
   } else {
     $cardnumber=$data->{'cardnumber'};
   }
-  
+
   if ($data->{'sex'} eq 'F'){
     $template->param(female => 1);
-  } 
-  
+  }
+
   my @titles = ('Miss', 'Mrs', 'Ms', 'Mr', 'Dr', 'Sir');
        # FIXME - Assumes English. This ought to be made part of i18n.
   my @titledata;
@@ -124,7 +126,7 @@ if ($delete){
     }
     push(@titledata, \%row);
   }
-  
+
   my ($categories,$labels)=ethnicitycategories();
   my $ethnicitycategoriescount=$#{$categories};
   my $ethcatpopup;
@@ -135,13 +137,13 @@ if ($delete){
                                -labels=>$labels);
        $template->param(ethcatpopup => $ethcatpopup); # bad style, has to be fixed
   }
-  
+
   ($categories,$labels)=borrowercategories();
   my $catcodepopup = CGI::popup_menu(-name=>'categorycode',
                                -values=>$categories,
                                -default=>$data->{'categorycode'},
                                -labels=>$labels);
-  
+
   my @areas = ('L','F','S','H','K','O','X','Z','V');
   my %arealabels = ('L' => 'Levin',
                  'F' => 'Foxton',
@@ -152,7 +154,7 @@ if ($delete){
                  'X' => 'Temporary Visitor',
                  'Z' => 'Interloan Libraries',
                  'V' => 'Village');
-                 
+
   my @areadata;
   while (@areas) {
     my %row;
@@ -166,8 +168,8 @@ if ($delete){
     $row{'area'}=$arealabels{$shortcut};
     push(@areadata, \%row);
   }
-  
-  
+
+
   my @relationships = ('workplace', 'relative','friend', 'neighbour');
   my @relshipdata;
   while (@relationships) {
@@ -180,12 +182,12 @@ if ($delete){
     }
     push(@relshipdata, \%row);
   }
-  
+
   # %flags: keys=$data-keys, datas=[formname, HTML-explanation]
   my %flags = ('gonenoaddress' => ['gna', 'Gone no address'],
                'lost'          => ['lost', 'Lost'],
                'debarred'      => ['debarred', 'Debarred']);
-  
+
   my @flagdata;
   foreach (keys(%flags)) {
     my $key = $_;
@@ -205,7 +207,7 @@ if ($delete){
   if ($modify){
     $template->param( modify => 1 );
   }
-  
+
   $template->param( startmenumember => join ('', startmenu('member')),
                        endmenumember   => join ('', endmenu('member')),
                        member          => $member,
@@ -234,8 +236,8 @@ if ($delete){
                        expiry          => $data->{'expiry'},
                        cardnumber      => $cardnumber,
                        dateofbirth     => $data->{'dateofbirth'});
-                       
+
   print "Content-Type: text/html\n\n", $template->output;
-  
+
 
 }
index 859dbe3..4c0b47b 100755 (executable)
--- a/modbib.pl
+++ b/modbib.pl
@@ -1,5 +1,7 @@
 #!/usr/bin/perl
 
+# $Id$
+
 #script to modify/delete biblios
 #written 8/11/99
 # modified 11/11/99 by chris@katipo.co.nz
@@ -39,7 +41,7 @@ my $sub        = $subject->[0]->{'subject'};
 my $additional = $addauthor->[0]->{'author'};
 my %inputs;
 my $dewey;
-my $submit=$input->param('submit.x');                                                                                              
+my $submit=$input->param('submit.x');
 if ($submit eq '') {
   print $input->redirect("/cgi-bin/koha/delbiblio.pl?biblio=$bibnum");
 } # if
index 1a392dd..0e59b60 100755 (executable)
@@ -1,5 +1,7 @@
 #!/usr/bin/perl
 
+# $Id$
+
 #script to modify/delete groups
 
 #written 8/11/99
@@ -36,7 +38,7 @@ my $bibitemnum=$input->param('bibitem');
 my $data=bibitemdata($bibitemnum);
 my $biblio=$input->param('biblio');
 my $submit=$input->param('submit.x');
-if ($submit eq ''){                                                                                                      
+if ($submit eq ''){
   print $input->redirect("deletebiblioitem.pl?biblioitemnumber=$bibitemnum&biblionumber=$biblio");
 }
 print $input->header;
@@ -54,14 +56,14 @@ my %inputs;
 #the value is a tab separated list, the first item being the input type
 #$inputs{'Author'}="text\t$data->{'author'}\t0";
 #$inputs{'Title'}="text\t$data->{'title'}\t1";
-my $dewey = $data->{'dewey'};                                                      
-$dewey =~ s/0+$//;                                                                 
-if ($dewey eq "000.") { $dewey = "";};                                             
-if ($dewey < 10){$dewey='00'.$dewey;}                                              
-if ($dewey < 100 && $dewey > 10){$dewey='0'.$dewey;}                               
-if ($dewey <= 0){                                                                  
-  $dewey='';                                                                       
-} 
+my $dewey = $data->{'dewey'};
+$dewey =~ s/0+$//;
+if ($dewey eq "000.") { $dewey = "";};
+if ($dewey < 10){$dewey='00'.$dewey;}
+if ($dewey < 100 && $dewey > 10){$dewey='0'.$dewey;}
+if ($dewey <= 0){
+  $dewey='';
+}
 $dewey=~ s/\.$//;
 $inputs{'Class'}="text\t$data->{'classification'}$dewey$data->{'subclass'}\t2";
 $inputs{'Item Type'}="text\t$data->{'itemtype'}\t3";
@@ -89,7 +91,7 @@ print <<printend
 
 <BLOCKQUOTE><FONT SIZE=6>
 <em><a href=/cgi-bin/koha/detail.pl?bib=$data->{'biblionumber'}&type=intra>$data->{'title'} ($data->{'author'})</a><br>
-Modify Group - $data->{'description'}</em></FONT><br>             
+Modify Group - $data->{'description'}</em></FONT><br>
 <form action=updatebibitem.pl method=post>
 <table border=0 cellspacing=0 cellpadding=5 align=left>
 
@@ -172,11 +174,11 @@ Tick ALL barcodes that changes are to apply too. Those left un-ticked will keep
 
 printend
 ;
-my (@items)=itemissues($data->{'biblioitemnumber'});                                                                        
-#print @items;                                                                                      
-my $count=@items;           
+my (@items)=itemissues($data->{'biblioitemnumber'});
+#print @items;
+my $count=@items;
 for (my $i=0;$i<$count;$i++){
-  $items[$i]->{'datelastseen'} = slashifyDate($items[$i]->{'datelastseen'});                                                      
+  $items[$i]->{'datelastseen'} = slashifyDate($items[$i]->{'datelastseen'});
   print <<printend
 <tr valign=top gcolor=#ffffcc>
 <td><input type=checkbox name="check_group_$items[$i]->{'barcode'}"></td>
@@ -203,10 +205,10 @@ print <<printend
 <B>HELP:</B> You <b>must</b> click on the appropriate radio button (in the green boxes), and choose to either re-assign the item/s to a record already in the system, or modify this record.  IF your changes only apply to some
  items, tick the appropriate ones and a new group record will be created automatically for them.
  <br clear=all>
+
  <p> &nbsp; </p>
+
+
 printend
 ;
 
index 33127c8..ef7c86d 100755 (executable)
@@ -1,5 +1,7 @@
 #!/usr/bin/perl
 
+# $Id$
+
 #script to modify/delete biblios
 #written 8/11/99
 # modified 11/11/99 by chris@katipo.co.nz
@@ -56,14 +58,14 @@ my %inputs;
 #the value is a tab separated list, the first item being the input type
 #$inputs{'Author'}="text\t$data->{'author'}\t0";
 #$inputs{'Title'}="text\t$data->{'title'}\t1";
-my $dewey = $data->{'dewey'};                                                      
-$dewey =~ s/0+$//;                                                                 
-if ($dewey eq "000.") { $dewey = "";};                                             
-if ($dewey < 10){$dewey='00'.$dewey;}                                              
-if ($dewey < 100 && $dewey > 10){$dewey='0'.$dewey;}                               
-if ($dewey <= 0){                                                                  
-  $dewey='';                                                                       
-} 
+my $dewey = $data->{'dewey'};
+$dewey =~ s/0+$//;
+if ($dewey eq "000.") { $dewey = "";};
+if ($dewey < 10){$dewey='00'.$dewey;}
+if ($dewey < 100 && $dewey > 10){$dewey='0'.$dewey;}
+if ($dewey <= 0){
+  $dewey='';
+}
 $dewey=~ s/\.$//;
 $inputs{'Barcode'}="text\t$item->{'barcode'}\t0";
 $inputs{'Class'}="hidden\t$data->{'classification'}$dewey$data->{'subclass'}\t2";
@@ -140,17 +142,17 @@ if ($item->{'wthdrawn'} ==0){
 }
 print <<printend
 >No</td></tr>
-<input type=hidden name=bibnum value="$data->{'biblionumber'}">        
+<input type=hidden name=bibnum value="$data->{'biblionumber'}">
 <input type=hidden name=bibitemnum value="$data->{'biblioitemnumber'}">
 <input type=hidden name=itemnumber value="$itemnum">
 <tr valign=top bgcolor=white><td></td><td>
 
-<input type=image  name=submit src=/images/save-changes.gif border=0 width=187 
+<input type=image  name=submit src=/images/save-changes.gif border=0 width=187
 height=42></td></tr>
 </table>
 </form></td></tr>
 </table>
-       
+
 printend
 ;
 
index 674f82f..fd67f84 100755 (executable)
@@ -1,5 +1,7 @@
 #!/usr/bin/perl
 
+# $Id$
+
 # Copyright 2000-2002 Katipo Communications
 #
 # This file is part of Koha.
@@ -25,7 +27,7 @@ use CGI;
 use C4::Search;
 use C4::Acquisitions;
 use C4::Output; # contains gettemplate
-  
+
 my $query=new CGI;
 
 my $includes = C4::Context->config('includes') ||
@@ -35,7 +37,7 @@ my $startfrom=$query->param('startfrom') || 0;
 
 my $template = gettemplate("catalogue/moredetail.tmpl");
 
-# get variables 
+# get variables
 
 my $biblionumber=$query->param('bib');
 my $title=$query->param('title');
@@ -87,7 +89,6 @@ foreach my $item (@items){
     } else {
        $item->{'issue'}="<b>Currently on issue to:</b> <a href=/cgi-bin/koha/moremember.pl?bornum=$item->{'borrower0'}>$item->{'card'}</a><br>";
     }
-         
 }
 
 $template->param(includesdir => $includes);
index 2baeec2..a4cd034 100755 (executable)
@@ -1,10 +1,12 @@
 #!/usr/bin/perl
 
+# $Id$
+
 # script to do a borrower enquiry/bring up borrower details etc
 # Displays all the details about a borrower
 # written 20/12/99 by chris@katipo.co.nz
 # last modified 21/1/2000 by chris@katipo.co.nz
-# modified 31/1/2001 by chris@katipo.co.nz 
+# modified 31/1/2001 by chris@katipo.co.nz
 #   to not allow items on request to be renewed
 #
 # needs html removed and to use the C4::Output more, but its tricky
@@ -88,7 +90,7 @@ if ($data->{'categorycode'} ne 'C'){
                           cardnumber => $guarantees->[$i]->{'cardnumber'}});
   }
   $template->param(guaranteeloop => \@guaranteedata);
-  
+
 } else {
   my ($guarantor)=findguarantor($data->{'borrowernumber'});
   unless ($guarantor->{'borrowernumber'} == 0){
@@ -100,8 +102,8 @@ my %bor;
 $bor{'borrowernumber'}=$bornum;
 
 # FIXME
-# it looks like $numaccts is a temp variable and that the 
-# for (my $i;$i<$numaccts;$i+++) 
+# it looks like $numaccts is a temp variable and that the
+# for (my $i;$i<$numaccts;$i++)
 # can be turned into a foreach loop instead
 #
 my ($numaccts,$accts,$total)=getboracctrecord('',\%bor);
@@ -114,7 +116,7 @@ for (my$i=0;$i<$numaccts;$i++){
   my $amount2= $accts->[$i]{'amountoutstanding'} + 0.00;
   my %row = %$accts->[$i];
   if ($amount2 != 0){
-    my $item=" &nbsp; ";  
+    my $item=" &nbsp; ";
     $row{'date'} = slashifyDate($accts->[$i]{'date'});
 
     if ($accts->[$i]{'accounttype'} ne 'Res'){
@@ -142,7 +144,7 @@ for (my $i=0;$i<$count;$i++){
   my $datedue=ParseDate($issue->[$i]{'date_due'});
   $issue->[$i]{'date_due'} = slashifyDate($issue->[$i]{'date_due'});
   my %row = %{$issue->[$i]};
-  if ($datedue < $today){  
+  if ($datedue < $today){
     $row{'red'}=1; #print "<font color=red>";
   }
   #find the charge for an item
@@ -172,8 +174,8 @@ for (my $i=0;$i<$count;$i++){
 my ($rescount,$reserves)=FindReserves('',$bornum); #From C4::Reserves2
 
 # FIXME
-# does it make sense to turn this into a foreach my $i (0..$rescount) 
-# kind of loop? 
+# does it make sense to turn this into a foreach my $i (0..$rescount)
+# kind of loop?
 #
 my @reservedata;
 for (my $i=0;$i<$rescount;$i++){
index 4f740ec..271b250 100755 (executable)
@@ -1,5 +1,7 @@
 #!/usr/bin/perl
 
+# $Id$
+
 #script to print confirmation screen, then if accepted calls itself to insert data
 
 
@@ -35,9 +37,9 @@ print $input->header;
 #get rest of data
 my %data;
 my @names=$input->param;
-foreach my $key (@names){                                                                                    
-  $data{$key}=$input->param($key);                                                                           
-}  
+foreach my $key (@names){
+  $data{$key}=$input->param($key);
+}
 my $ok=0;
 
 my $string="The following compulsary fields have been left blank. Please push the back button
@@ -72,16 +74,16 @@ if ($ok ==1){
   if ($valid != 1){
     print "Invalid cardnumber";
   } else {
-    
+
      my @inputs;
      my $i=0;
      while (my ($key, $value) = each %data) {
        $value=~ s/\"/%22/g;
        $inputs[$i]=["hidden","$key","$value"];
-       $i++;                                  
-     }                                        
+       $i++;
+     }
      $inputs[$i]=["submit","submit","submit"];
-     print mkformnotable("/cgi-bin/koha/insertidata.pl",@inputs);   
+     print mkformnotable("/cgi-bin/koha/insertidata.pl",@inputs);
   }
 }
 print endmenu('member');
index 0c1a4cf..1d20a7e 100755 (executable)
@@ -1,5 +1,6 @@
 #!/usr/bin/perl
 
+# $Id$
 
 # Copyright 2000-2002 Katipo Communications
 #
@@ -29,7 +30,7 @@ my $type=$input->param('type');
 
 my $theme = $input->param('theme'); # only used if allowthemeoverride is set
 my %tmpldata = pathtotemplate ( template => 'overdue.tmpl', theme => $theme);
-my $template = HTML::Template->new( filename => $tmpldata{'path'}, 
+my $template = HTML::Template->new( filename => $tmpldata{'path'},
                                    die_on_bad_params => 0);
 my $duedate;
 my $bornum;
@@ -57,7 +58,7 @@ while (my $data=$sth->fetchrow_hashref) {
   $duedate=$data->{'date_due'};
   $bornum=$data->{'borrowernumber'};
   $itemnum=$data->{'itemnumber'};
-  
+
   my $query="select concat(firstname,' ',surname),phone,emailaddress from borrowers where borrowernumber='$bornum'";
   my $sth1=$dbh->prepare($query);
   $sth1->execute;
@@ -101,5 +102,5 @@ $template->param( startmenureport => join ('', startmenu('report')),
                endmenureport     => join ('', endmenu('report')),
                todaysdate        => $todaysdate,
                overdueloop       => \@overduedata );
-                       
+
 print "Content-Type: text/html\n\n", $template->output;
diff --git a/pay.pl b/pay.pl
index a58b8f6..446a58b 100755 (executable)
--- a/pay.pl
+++ b/pay.pl
@@ -1,6 +1,8 @@
 #!/usr/bin/perl
 
-#wrriten 11/1/2000 by chris@katipo.oc.nz
+# $Id$
+
+#written 11/1/2000 by chris@katipo.oc.nz
 #part of the koha library system, script to facilitate paying off fines
 
 
@@ -42,7 +44,7 @@ my $user=$input->remote_user;
 
 #get account details
 my %bor;
-$bor{'borrowernumber'}=$bornum;                            
+$bor{'borrowernumber'}=$bornum;
 
 
 my @names=$input->param;
@@ -77,7 +79,7 @@ if ($check ==0){
   if ($total ne ''){
     recordpayment(\%env,$bornum,$total);
   }
-  my ($numaccts,$accts,$total)=getboracctrecord('',\%bor);     
+  my ($numaccts,$accts,$total)=getboracctrecord('',\%bor);
 
   print startpage();
   print startmenu('member');
@@ -143,7 +145,7 @@ printend
 } else {
 #  my $quety=$input->query_string;
 #  print $input->redirect("/cgi-bin/koha/sec/writeoff.pl?$quety");
-    my%inp;    
+    my%inp;
     my @name=$input->param;
     for (my $i=0;$i<@name;$i++){
        my $test=$input->param($name[$i]);
index 1f34d1b..b6e7ab7 100755 (executable)
@@ -1,5 +1,7 @@
 #!/usr/bin/perl
 
+# $Id$
+
 #written 18/1/2000 by chris@katipo.co.nz
 #script to renew items from the web
 
@@ -53,6 +55,6 @@ while ( my ($key, $value) = each %data) {
        renewbook(\%env,$bornum,$key);
      }
    }
-}      
+}
 
 print $input->redirect("/cgi-bin/koha/moremember.pl?bornum=$bornum");
index 6234e36..2276b22 100755 (executable)
@@ -1,5 +1,7 @@
 #!/usr/bin/perl
 
+# $Id$
+
 #script to display reports
 #written 8/11/99
 
@@ -34,7 +36,7 @@ print startpage();
 print startmenu('issue');
 my @data;
 if ($type eq 'search'){
- @data=statsreport('search','something');  
+ @data=statsreport('search','something');
 }
 if ($type eq 'issue'){
  @data=statsreport('issue','today');
index 8ed764e..675625c 100755 (executable)
@@ -1,5 +1,7 @@
 #!/usr/bin/perl
 
+# $Id$
+
 #script to place reserves/requests
 #writen 2/1/00 by chris@katipo.oc.nz
 
@@ -89,7 +91,7 @@ foreach my $dat (sort {$b->{'dateaccessioned'} cmp $a->{'dateaccessioned'}} @dat
     $dat->{'dewey'}=~ s/00$//;
     my $class="$dat->{'classification'}$dat->{'dewey'}$dat->{'subclass'}";
     my $select;
-    if (($dat->{'notforloan'}) 
+    if (($dat->{'notforloan'})
        || ($dat->{'itemlost'} == 1))  {
        $select = "Cannot be reserved.";
     } else {
@@ -215,7 +217,7 @@ print <<printend
 <input type=hidden name=type value=str8>
 <input type=hidden name=title value="$dat->{'title'}">
 <FONT SIZE=6><em>Requesting: <br>
-<a href=/cgi-bin/koha/detail.pl?bib=$bib>$dat->{'title'}</a> 
+<a href=/cgi-bin/koha/detail.pl?bib=$bib>$dat->{'title'}</a>
 ($dat->{'author'})</em></FONT><P>
 <p>
 
@@ -242,7 +244,7 @@ $priorityoptions
 <td><select name=pickup>
 $branchoptions
 </select></td>
-<td><input type=checkbox name=request value=any>Next Available, 
+<td><input type=checkbox name=request value=any>Next Available,
 <br>(or choose from list below)</td>
 </tr></table>
 
index 10f95bf..2b49a94 100755 (executable)
@@ -1,5 +1,7 @@
 #!/usr/bin/perl
 
+# $Id$
+
 #script to show list of budgets and bookfunds
 #written 4/2/00 by chris@katipo.co.nz
 #called as an include by the acquisitions index page
@@ -53,7 +55,7 @@ for (my $i=0;$i<$count;$i++){
   my $avail=$results[$i]->{'budgetamount'}-($spent+$comtd);
   print  <<EOP
 <tr><td>
-$results[$i]->{'bookfundname'} </TD> 
+$results[$i]->{'bookfundname'} </TD>
 <TD>$results[$i]->{'budgetamount'}</TD> <TD>
 EOP
 ;
index 3df29d4..49c604d 100755 (executable)
--- a/stats.pl
+++ b/stats.pl
@@ -1,5 +1,7 @@
 #!/usr/bin/perl
 
+# $Id$
+
 #written 14/1/2000
 #script to display reports
 
@@ -80,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'},
@@ -98,7 +100,7 @@ while ($i<$count){
         if ($charges[$i2]->{'accounttype'} eq 'R'){
          $temptotalren+=$charges[$i2]->{'amount'}-$charges[$i2]->{'amountoutstanding'};
         }
-     }   
+     }
   }
 
 #  my $branch=
@@ -134,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 {
@@ -153,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);
@@ -161,7 +163,7 @@ while ($i<$count){
     $oldtime=$payments[$i]{'timestamp'};
     $bornum=$payments[$i]{'borrowernumber'};
     $i++;
-  
+
   }
   print mktablerow('6','white','','','','','','');
 }
index ed45099..8944b02 100755 (executable)
--- a/stats2.pl
+++ b/stats2.pl
@@ -1,5 +1,7 @@
 #!/usr/bin/perl
 
+# $Id$
+
 #written 14/1/2000
 #script to display reports
 
@@ -60,11 +62,11 @@ $date=UnixDate($date,'%Y-%m-%d');
 $date2=UnixDate($date2,'%Y-%m-%d');
 
 my $dbh = C4::Context->dbh;
-my $query="select * 
+my $query="select *
 from accountlines,accountoffsets,borrowers where
 accountlines.borrowernumber=accountoffsets.borrowernumber and
 (accountlines.accountno=accountoffsets.accountno or accountlines.accountno
-=accountoffsets.offsetaccount) and accountlines.timestamp >=20000621000000 
+=accountoffsets.offsetaccount) and accountlines.timestamp >=20000621000000
 and borrowers.borrowernumber=accountlines.borrowernumber
 group by accountlines.borrowernumber,accountlines.accountno";
 my $sth=$dbh->prepare($query);
index e5a4c3e..ebfde88 100755 (executable)
@@ -1,5 +1,7 @@
 #!/usr/bin/perl
 
+# $Id$
+
 #script to display detailed information
 #written 8/11/99
 
@@ -37,15 +39,15 @@ my $env;
 my $subject=$input->param('subject');
 #my $title=$input->param('title');
 
-my $main;                                                                                                                                 
-my $secondary;                                                                                                                            
-if ($type eq 'opac'){                                                                                                                     
-  $main='#99cccc';                                                                                                                        
-  $secondary='#efe5ef';                                                                                                                   
-} else {                                                                                                                                  
-  $main='#99cc33';                                                                                                                        
-  $secondary='#ffffcc';                                                                                                                   
-}      
+my $main;
+my $secondary;
+if ($type eq 'opac'){
+  $main='#99cccc';
+  $secondary='#efe5ef';
+} else {
+  $main='#99cc33';
+  $secondary='#ffffcc';
+}
 
 my @items=subsearch(\$blah,$subject);
 #print @items;
@@ -54,9 +56,9 @@ my $i=0;
 print center();
 print mktablehdr;
 if ($type ne 'opac'){
-  print mktablerow(5,$main,bold('TITLE'),bold('AUTHOR'),bold('COUNT'),bold('LOCATION'),' ',"/images/background-mem.gif"); 
+  print mktablerow(5,$main,bold('TITLE'),bold('AUTHOR'),bold('COUNT'),bold('LOCATION'),' ',"/images/background-mem.gif");
 } else {
-  print mktablerow(5,$main,bold('TITLE'),bold('AUTHOR'),bold('COUNT'),bold('BRANCH'),' &nbsp; '); 
+  print mktablerow(5,$main,bold('TITLE'),bold('AUTHOR'),bold('COUNT'),bold('BRANCH'),' &nbsp; ');
 }
 my $colour=1;
 while ($i < $count){
@@ -66,45 +68,45 @@ while ($i < $count){
   $word=~ s/ /%20/g;
   #$word=~ s/\,/\,%20/;
   $results[1]=mklink("/cgi-bin/koha/search.pl?author=$word&type=$type",$results[1]);
-  my ($count,$lcount,$nacount,$fcount,$scount)=itemcount($env,$results[2]);                                                                     
-  $results[3]=$count;                                                                                                                           
-  if ($nacount > 0){                                                                                                                          
-    $results[4]=$results[4]."On Loan";                                                                                                          
+  my ($count,$lcount,$nacount,$fcount,$scount)=itemcount($env,$results[2]);
+  $results[3]=$count;
+  if ($nacount > 0){
+    $results[4]=$results[4]."On Loan";
     if ($nacount > 1){
       $results[4].=" $nacount";
     }
     $results[4].=" ";
-  }                                                                                                                                           
-  if ($lcount > 0){                                                                                                                           
-    $results[4]=$results[4]." Levin";                                                                                                          
+  }
+  if ($lcount > 0){
+    $results[4]=$results[4]." Levin";
     if ($lcount > 1){
       $results[4].=" $lcount";
     }
     $results[4].=" ";
-  }                                                                                                                                           
-  if ($fcount > 0){                                                                                                                           
-    $results[4]=$results[4]." Foxton";                                                                                                          
+  }
+  if ($fcount > 0){
+    $results[4]=$results[4]." Foxton";
     if ($fcount > 1){
       $results[4].=" $fcount";
     }
     $results[4].=" ";
-  }                                                                                                                                           
-  if ($scount > 0){                                                                                                                           
-    $results[4]=$results[4]." Shannon";                                                                                                          
+  }
+  if ($scount > 0){
+    $results[4]=$results[4]." Shannon";
     if ($scount > 1){
       $results[4].=" $scount";
     }
     $results[4].=" ";
-  }             
+  }
   if ($type ne 'opac'){
     $results[6]=mklink("/cgi-bin/koha/request.pl?bib=$results[2]","Request");
   }
-  if ($colour == 1){                                                                          
-    print mktablerow(5,$secondary,$results[0],$results[1],$results[3],$results[4],$results[6]);                                        
-    $colour=0;                                                                   
-  } else{                                                                        
-    print mktablerow(5,'white',$results[0],$results[1],$results[3],$results[4],$results[6]);                                     
-    $colour=1;                                                                                
+  if ($colour == 1){
+    print mktablerow(5,$secondary,$results[0],$results[1],$results[3],$results[4],$results[6]);
+    $colour=0;
+  } else{
+    print mktablerow(5,'white',$results[0],$results[1],$results[3],$results[4],$results[6]);
+    $colour=1;
   }
    $i++;
 }
index 31783bf..bebc1d0 100755 (executable)
@@ -1,4 +1,7 @@
 #!/usr/bin/perl
+
+# $Id$
+
 #
 # written 31/5/00 by chris@katipo.co.nz to make a way to fix account mistakes
 #
@@ -37,13 +40,13 @@ my @name=$input->param;
 foreach my $key (@name){
   if ($key ne 'bornum'){
     my $temp=$input->param($key);
-    
+
 #    print $temp,$key;
     if ($temp ne ''){
       fixaccounts($bornum,$key,$temp);
-   
+
     }
   }
 }
-    
+
 print $input->redirect("boraccount.pl?bornum=$bornum");
index f8c6cb6..cf19a3e 100755 (executable)
@@ -1,5 +1,6 @@
 #!/usr/bin/perl
 
+# $Id$
 
 # Copyright 2000-2002 Katipo Communications
 #
@@ -69,7 +70,7 @@ if ($class =~/[0-9]+/) {
 } # else
 
 my (@items) = &itemissues($bibitemnum);
-#print @items;           
+#print @items;
 my $count   = @items;
 #print $count;
 my @barcodes;
@@ -136,7 +137,7 @@ if ($existing eq 'YES'){
                    });
        }
       }
-      
+
    } elsif ($flag2 eq 'leastone') {
       &modbibitem({
          biblioitemnumber => $bibitemnum,
@@ -160,16 +161,16 @@ if ($existing eq 'YES'){
       } else {
         $loan=0;
       }
-       for (my $i=0;$i<$count;$i++){                                             
-         if ($barcodes[$i] ne ''){                                               
+       for (my $i=0;$i<$count;$i++){
+         if ($barcodes[$i] ne ''){
            moditem( {biblionumber => $bibnum,
                      loan         => $loan,
                      itemnumber   => $items[$i]->{'itemnumber'},
                      bibitemnum   => $bibitemnum
                      });
-         }                                                                       
+         }
        }
-      
+
    } else {
      &modbibitem({
          biblioitemnumber => $bibitemnum,
index 07f0985..4241d73 100755 (executable)
@@ -1,5 +1,7 @@
 #!/usr/bin/perl
 
+# $Id$
+
 #script to update charges for overdue in database
 #updates categoryitem
 # is called by charges.pl
@@ -39,14 +41,14 @@ my $dbh = C4::Context->dbh;
 my @names=$input->param();
 
 foreach my $key (@names){
-  
+
   my $bor=substr($key,0,1);
   my $cat=$key;
   $cat =~ s/[A-Z]//i;
   my $data=$input->param($key);
   my @dat=split(',',$data);
 #  print "$bor $cat $dat[0] $dat[1] $dat[2] <br> ";
-  my $sth=$dbh->prepare("Update categoryitem set fine=$dat[0],startcharge=$dat[1],chargeperiod=$dat[2] where 
+  my $sth=$dbh->prepare("Update categoryitem set fine=$dat[0],startcharge=$dat[1],chargeperiod=$dat[2] where
   categorycode='$bor' and itemtype='$cat'");
   $sth->execute;
   $sth->finish;
index 16390e0..c280b13 100755 (executable)
@@ -1,5 +1,6 @@
 #!/usr/bin/perl
 
+# $Id$
 
 # Copyright 2000-2002 Katipo Communications
 #
@@ -111,11 +112,11 @@ if ($wthdrawn == 0 && $override ne 'yes'){
   }
   print $input->redirect("moredetail.pl?type=intra&bib=$bibnum&bi=$bibitemnum");
 } else {
-  
+
 #  print "marking cancelled";
   #need to check if it is on reserve or issued
   my $dbh = C4::Context->dbh;
-  my $flag=0; 
+  my $flag=0;
   my ($resbor,$resrec)=C4::Circulation::Circ2::checkreserve($env,$dbh,$itemnum);
  # print $resbor;
   if ($resbor){
@@ -123,7 +124,7 @@ if ($wthdrawn == 0 && $override ne 'yes'){
     print "The biblio or biblioitem this item belongs to has a reserve on it";
     $flag=1;
   }
-  my $sth=$dbh->prepare("Select * from issues where (itemnumber='$itemnum') and (returndate is null)"); 
+  my $sth=$dbh->prepare("Select * from issues where (itemnumber='$itemnum') and (returndate is null)");
   $sth->execute;
   my $data=$sth->fetchrow_hashref;
   if ($data->{'borrowernumber'} ne '') {
@@ -160,4 +161,3 @@ sub checkinp{
 }
 
 #sub checkissue{
-  
index bde44b0..a17596c 100755 (executable)
@@ -1,5 +1,6 @@
 #!/usr/bin/perl
 
+# $Id$
 
 # Copyright 2000-2002 Katipo Communications
 #
@@ -39,7 +40,7 @@ if ($input->param('delete')) {
 
 } elsif (! $biblionumber) {
     print $input->redirect("/catalogue/");
-    
+
 } elsif (! $websitenumber) {
     print $input->redirect("modwebsites.pl?biblionumber=$biblionumber");