circ subdir - Dates.pm integration and warnings fixes.

Signed-off-by: Chris Cormack <crc@liblime.com>
Signed-off-by: Joshua Ferraro <jmf@liblime.com>
This commit is contained in:
Joe Atzberger 2007-12-04 17:40:55 -06:00 committed by Joshua Ferraro
parent fe00a94164
commit 82b8c496fd
10 changed files with 29 additions and 43 deletions

View File

@ -30,7 +30,7 @@ use C4::Koha;
use C4::Auth;
use C4::Branch; # GetBranches
use C4::Biblio; # GetBiblioItemData
use C4::Date;
use C4::Dates;
my $input = new CGI;
my $itm = $input->param('itm');

View File

@ -21,7 +21,7 @@ use C4::Context;
use CGI;
use C4::Output;
use C4::Auth;
use C4::Date;
use C4::Dates;
use C4::Overdues; # AddNotifyLine
use C4::Biblio;
use C4::Koha;

View File

@ -27,7 +27,7 @@ use CGI;
use C4::Output;
use C4::Print;
use C4::Auth qw/:DEFAULT get_session/;
use C4::Date;
use C4::Dates;
use C4::Branch; # GetBranches
use C4::Koha; # GetPrinter
use C4::Circulation;
@ -141,7 +141,7 @@ if($duedatespec) {
# ($year, $month, $day) = ($duedatespec) ? split /-/, $duedatespec : (0,0,0);
#}
my @datearr = localtime( time() );
my @datearr = localtime();
# FIXME - Could just use POSIX::strftime("%Y%m%d", localtime);
my $todaysdate =

View File

@ -24,21 +24,19 @@ use C4::Output;
use CGI;
use C4::Auth;
use C4::Branch;
use C4::Date;
use C4::Dates;
my $input = new CGI;
my $type = $input->param('type');
my $theme = $input->param('theme'); # only used if allowthemeoverride is set
my $order=$input->param('order');
my $bornamefilter=$input->param('borname');
my $borcatfilter=$input->param('borcat');
my $itemtypefilter=$input->param('itemtype');
my $borflagsfilter=$input->param('borflags') || " ";
my $branchfilter=$input->param('branch');
my $showall=$input->param('showall');
my $theme = $input->param('theme'); # only used if allowthemeoverride is set
my $type = $input->param('type');
my $theme = $input->param('theme'); # only used if allowthemeoverride is set
my $order = $input->param('order');
my $showall = $input->param('showall');
my $bornamefilter = $input->param('borname');
my $borcatfilter = $input->param('borcat');
my $itemtypefilter = $input->param('itemtype');
my $borflagsfilter = $input->param('borflags') || " ";
my $branchfilter = $input->param('branch');
my ( $template, $loggedinuser, $cookie ) = get_template_and_user(
{

View File

@ -31,7 +31,7 @@ use C4::Context;
use C4::Auth;
use C4::Output;
use C4::Circulation;
use C4::Date;
use C4::Dates;
use C4::Print;
use C4::Reserves;
use C4::Biblio;

View File

@ -78,8 +78,8 @@ warn "d : $date // d2 : $date2";
my @payments = TotalPaid( $date, $date2 );
my $count = @payments;
my $total = 0;
my $totalw = 0;
my $oldtime;
my $totalw = 0;
my @loop;
my %row;
my $i = 0;
@ -136,11 +136,7 @@ while ( $i < $count ) {
}
}
}
my $hour = substr( $payments[$i]{'timestamp'}, 8, 2 );
my $min = substr( $payments[$i]{'timestamp'}, 10, 2 );
my $sec = substr( $payments[$i]{'timestamp'}, 12, 2 );
my $time = "$hour:$min:$sec";
my $time2 = "$payments[$i]{'date'}";
my $time2 = $payments[$i]{'date'};
my $branch = Getpaidbranch( $time2, $payments[$i]{'borrowernumber'} );
my $borrowernumber = $payments[$i]{'borrowernumber'};
my $oldtime = $payments[$i]{'timestamp'};
@ -150,12 +146,8 @@ while ( $i < $count ) {
&& $oldtype == $payments[$i]{'accounttype'}
&& $oldtime eq $payments[$i]{'timestamp'} )
{
my $hour = substr( $payments[$i]{'timestamp'}, 8, 2 );
my $min = substr( $payments[$i]{'timestamp'}, 10, 2 );
my $sec = substr( $payments[$i]{'timestamp'}, 12, 2 );
my $time = "$hour:$min:$sec";
my $time2 = "$payments[$i]{'date'}";
my $branch = Getpaidbranch( $time2, $payments[$i]{'borrowernumber'} );
my $xtime2 = $payments[$i]{'date'};
my $branch = Getpaidbranch( $xtime2, $payments[$i]{'borrowernumber'} );
if ( $payments[$i]{'accounttype'} eq 'W' ) {
$totalw += $payments[$i]{'amount'};
}

View File

@ -24,7 +24,7 @@ use C4::Output;
use CGI;
use C4::Branch; # GetBranches
use C4::Auth;
use C4::Date;
use C4::Dates;
use C4::Circulation;
use C4::Reserves;
use C4::Members;

View File

@ -24,7 +24,7 @@ use C4::Context;
use C4::Output;
use C4::Branch;
use C4::Auth;
use C4::Date;
use C4::Dates;
use C4::Biblio;
use C4::Circulation;
use C4::Members;
@ -41,7 +41,7 @@ my $input = new CGI;
my $theme = $input->param('theme'); # only used if allowthemeoverride is set
my $itemnumber = $input->param('itemnumber');
my $todaysdate = join "-", &Today;
# if we have a resturn of the form to delete the transfer, we launch the subrroutine
if ($itemnumber) {
@ -93,15 +93,11 @@ foreach my $br ( keys %$branches ) {
my $gettitle = GetBiblioFromItemNumber( $num->{'itemnumber'} );
my $itemtypeinfo = getitemtypeinfo( $gettitle->{'itemtype'} );
$getransf{'title'} = $gettitle->{'title'};
$getransf{'datetransfer'} = format_date( $num->{'datesent'} );
$getransf{'biblionumber'} = $gettitle->{'biblionumber'};
$getransf{'itemnumber'} = $gettitle->{'itemnumber'};
$getransf{'barcode'} = $gettitle->{'barcode'};
$getransf{'itemtype'} = $itemtypeinfo->{'description'};
$getransf{'homebranch'} = $gettitle->{'homebranch'};
$getransf{'holdingbranch'} = $gettitle->{'holdingbranch'};
$getransf{'itemcallnumber'} = $gettitle->{'itemcallnumber'};
$getransf{'itemtype'} = $itemtypeinfo->{'description'};
foreach (qw(title biblionumber itemnumber barcode homebranch holdingbranch itemcallnumber)) {
$getransf{$_} = $gettitle->{$_};
}
# we check if we have a reserv for this transfer
my @checkreserv = GetReservesFromItemnumber($num->{'itemnumber'} );
@ -128,7 +124,7 @@ foreach my $br ( keys %$branches ) {
$template->param(
branchesloop => \@branchesloop,
show_date => format_date($todaysdate),
show_date => format_date(join("-", &Today)),
);
output_html_with_http_headers $input, $cookie, $template->output;

View File

@ -24,7 +24,7 @@ use C4::Context;
use C4::Output;
use C4::Branch; # GetBranchName
use C4::Auth;
use C4::Date;
use C4::Dates;
use C4::Circulation;
use C4::Members;
use C4::Biblio;

View File

@ -35,7 +35,7 @@ my $query = $input->param('query');
print $input->header(-type => 'text/plain', -charset => 'ISO-8859-1');
my $dbh = C4::Context->dbh;
my $query = "SELECT surname, firstname, cardnumber, address, city, zipcode ".
$query = "SELECT surname, firstname, cardnumber, address, city, zipcode ".
"FROM borrowers " .
"WHERE surname LIKE '". $query . "%' " .
"OR firstname LIKE '" . $query . "%' " .