[Koha-cvs] Changes to koha/circ/circulation.pl [rel_2_2]
Henri-Damien LAURENT
laurenthdl at alinto.com
Tue Nov 29 15:50:30 CET 2005
Index: koha/circ/circulation.pl
diff -u koha/circ/circulation.pl:1.81.2.5 koha/circ/circulation.pl:1.81.2.6
--- koha/circ/circulation.pl:1.81.2.5 Tue Jul 19 18:50:49 2005
+++ koha/circ/circulation.pl Tue Nov 29 14:50:29 2005
@@ -35,6 +35,7 @@
use C4::Koha;
use HTML::Template;
use C4::Date;
+use Date::Manip;
#
# PARAMETERS READING
@@ -123,6 +124,13 @@
if ($borrowernumber) {
$borrower = getpatroninformation(\%env,$borrowernumber,0);
my ($od,$issue,$fines)=borrdata2(\%env,$borrowernumber);
+ warn $borrower->{'expiry'};
+ my $warningdate = DateCalc($borrower->{'expiry'},"- ".C4::Context->preference('NotifiyBorrowerDeparture')." days");
+ my $warning=Date_Cmp(ParseDate("today"),$warningdate);
+ if ($warning>0){
+ #borrowercard expired
+ $template->param(warndeparture=>$warning);
+ }
$template->param(overduecount => $od,
issuecount => $issue,
finetotal => $fines);
More information about the Koha-cvs
mailing list