bug fix : for item reservation, now the system don't keep the reserve if the document...
authoralaurin <alaurin>
Tue, 6 Jun 2006 12:26:57 +0000 (12:26 +0000)
committeralaurin <alaurin>
Tue, 6 Jun 2006 12:26:57 +0000 (12:26 +0000)
C4/Circulation/Circ2.pm
circ/circulation.pl
reserve/placerequest.pl
reserve/request.pl

index 25dc99a..d592230 100755 (executable)
@@ -1980,7 +1980,7 @@ sub get_return_date_of {
 SELECT date_due,
        itemnumber
   FROM issues
-  WHERE itemnumber IN ('.join(',', @itemnumbers).')
+  WHERE itemnumber IN ('.join(',', @itemnumbers).') AND returndate IS NULL
 ';
     return get_infos_of($query, 'itemnumber', 'date_due');
 }
index 79f942b..06a617e 100755 (executable)
@@ -138,7 +138,6 @@ my $picture;
 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('NotifyBorrowerDeparture') . "  days" );
index 00474b9..e7716ad 100755 (executable)
@@ -44,7 +44,6 @@ my @rank=$input->param('rank-request');
 my $type=$input->param('type');
 my $title=$input->param('title');
 my $bornum=borrdata($borrower,'');
-# Nouveau developpement
 my $checkitem=$input->param('checkitem');
 # my $priority;
 my $found;
index 19dbda0..fd62b63 100755 (executable)
@@ -105,7 +105,7 @@ if ($cardnumber) {
         }
 
 # we check the date expiricy of the borrower
-       my $warning=Date_Cmp(ParseDate("today"),format_date($borrowerinfo->{'expiry'}));
+       my $warning=Date_Cmp(ParseDate("today"),format_date($borrowerinfo->{'dateexpiry'}));
        if ( $warning > 0) {
                        $expiry = 1;
        }
@@ -253,7 +253,7 @@ foreach my $biblioitemnumber (@biblioitemnumbers) {
 
         if (defined $return_date_of->{$itemnumber}) {
             $date_due = format_date($return_date_of->{$itemnumber});
-
+           $item->{date_due} = $date_due;
             $item->{backgroundcolor} = 'onloan';
         }