koha-cvs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Koha-cvs] koha/circ circulation.pl [rel_2_2]


From: Waylon Robertson
Subject: [Koha-cvs] koha/circ circulation.pl [rel_2_2]
Date: Sun, 28 Jan 2007 21:01:36 +0000

CVSROOT:        /sources/koha
Module name:    koha
Branch:         rel_2_2
Changes by:     Waylon Robertson <genji>        07/01/28 21:01:36

Modified files:
        circ           : circulation.pl 

Log message:
        Fix for 1169, issuedate wasn't formatted properly, to compare with 
today's date. Fixed in rel_2_2

CVSWeb URLs:
http://cvs.savannah.gnu.org/viewcvs/koha/circ/circulation.pl?cvsroot=koha&only_with_tag=rel_2_2&r1=1.81.2.17&r2=1.81.2.18

Patches:
Index: circulation.pl
===================================================================
RCS file: /sources/koha/koha/circ/circulation.pl,v
retrieving revision 1.81.2.17
retrieving revision 1.81.2.18
diff -u -b -r1.81.2.17 -r1.81.2.18
--- circulation.pl      28 Jan 2007 01:53:31 -0000      1.81.2.17
+++ circulation.pl      28 Jan 2007 21:01:36 -0000      1.81.2.18
@@ -86,7 +86,7 @@
 my @datearr = localtime(time());
 # FIXME - Could just use POSIX::strftime("%Y%m%d", localtime);
 my $todaysdate = (1900+$datearr[5]).sprintf ("%0.2d", ($datearr[4]+1)).sprintf 
("%0.2d", ($datearr[3]));
-
+warn $todaysdate;
 
 # check and see if we should print
  if ($barcode eq ''  && $print eq 'maybe'){
@@ -199,7 +199,9 @@
        # split in 2 arrays for today & previous
        foreach my $it (keys %$issueslist) {
                my $issuedate = $issueslist->{$it}->{'timestamp'};
-               $issuedate = substr($issuedate, 0, 8);
+               $issuedate = substr($issuedate, 0, 10);
+               $issuedate=~s/-//g;
+               warn $issuedate;
                if ($todaysdate == $issuedate) {
                        push @todaysissues, $issueslist->{$it};
                } else {




reply via email to

[Prev in Thread] Current Thread [Next in Thread]