From 3568e20644447b9611749ab1add2ae902dbdbfcf Mon Sep 17 00:00:00 2001 From: Paul POULAIN Date: Mon, 24 Sep 2007 16:26:30 +0200 Subject: [PATCH] bug fixing on 1396 : Conflicts: circ/circulation.pl Signed-off-by: Chris Cormack --- circ/circulation.pl | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/circ/circulation.pl b/circ/circulation.pl index 8009da9ee3..8a416893ce 100755 --- a/circ/circulation.pl +++ b/circ/circulation.pl @@ -196,11 +196,12 @@ if ($borrowernumber) { my ( $today_year, $today_month, $today_day ) = Today(); my ( $warning_year, $warning_month, $warning_day ) = split /-/, $borrower->{'dateexpiry'}; - + my ( $enrol_year, $enrol_month, $enrol_day ) = split /-/, + $borrower->{'dateenrolled'}; # Renew day is calculated by adding the enrolment period to today my ( $renew_year, $renew_month, $renew_day ) = - Add_Delta_YM( $today_year, $today_month, $today_day, - $borrower->{'enrolmentperiod'}, 0 ); + Add_Delta_YM( $enrol_year, $enrol_month, $enrol_day, + 0 , $borrower->{'enrolmentperiod'}) if ($enrol_year*$enrol_month*$enrol_day>0); # if the expiry date is before today if ( Date_to_Days( $today_year, $today_month, $today_day ) > Date_to_Days( $warning_year, $warning_month, $warning_day ) )