Updated the date calculations so they work now

This commit is contained in:
bob_lyon 2006-12-19 03:28:22 +00:00
parent 46f1eb1517
commit ae91208535
1 changed files with 3 additions and 3 deletions

View File

@ -10,7 +10,7 @@ use C4::Output;
use C4::Interface::CGI::Output;
use C4::Context;
use HTML::Template;
use Date::Calc;
use Date::Calc qw(:all);
my $query = new CGI;
my $op = $query->param('op');
@ -127,8 +127,8 @@ my ($user, $cookie, $sessionID, $flags)
my $weekarrayjs='';
my $count = 0;
my ($year, $month, $day) = Date::Calc::Today;
my $firstday = Day_of_Year($month,$day,$year);
my $wkno = Week_of_Year($month,$day,$year,1); # week starting monday
my $firstday = Day_of_Year($year,$month,$day);
my $wkno = Week_of_Year($year,$month,$day); # week starting monday
my $weekno = $wkno;
for(my $i=$firstday;$i<($firstday+365);$i=$i+7){
$count = $i;