[Koha-cvs] koha/C4/Circulation Circ2.pm [rel_3_0]

Antoine Farnault antoine at koha-fr.org
Wed Sep 20 17:50:46 CEST 2006


CVSROOT:	/sources/koha
Module name:	koha
Branch:		rel_3_0
Changes by:	Antoine Farnault <toins>	06/09/20 15:50:45

Modified files:
	C4/Circulation : Circ2.pm 

Log message:
	sync with dev_week : (add isbn and ccode to template loop)
	And some code clean (code which is depend on reserve)

CVSWeb URLs:
http://cvs.savannah.gnu.org/viewcvs/koha/C4/Circulation/Circ2.pm?cvsroot=koha&only_with_tag=rel_3_0&r1=1.114.2.4&r2=1.114.2.5

Patches:
Index: Circ2.pm
===================================================================
RCS file: /sources/koha/koha/C4/Circulation/Circ2.pm,v
retrieving revision 1.114.2.4
retrieving revision 1.114.2.5
diff -u -b -r1.114.2.4 -r1.114.2.5
--- Circ2.pm	6 Sep 2006 12:46:32 -0000	1.114.2.4
+++ Circ2.pm	20 Sep 2006 15:50:45 -0000	1.114.2.5
@@ -3,7 +3,7 @@
 
 package C4::Circulation::Circ2;
 
-# $Id: Circ2.pm,v 1.114.2.4 2006/09/06 12:46:32 btoumi Exp $
+# $Id: Circ2.pm,v 1.114.2.5 2006/09/20 15:50:45 toins Exp $
 
 #package to deal with Returns
 #written 3/11/99 by olwen at katipo.co.nz
@@ -1449,8 +1449,8 @@
 		}
 		$flags{'ODUES'} = \%flaginfo;
 	}
-	my ($nowaiting, $itemswaiting)
-			= CheckWaiting($patroninformation->{'borrowernumber'});
+	my $itemswaiting=GetWaitingReserves($patroninformation->{'borrowernumber'});
+	my $nowaiting = scalar @$itemswaiting;	
 	if ($nowaiting > 0) {
 		my %flaginfo;
 		$flaginfo{'message'} = "Reserved items available";
@@ -1680,6 +1680,8 @@
 				biblioitems.dewey     AS dewey,
 				itemtypes.description AS itemtype,
 				biblioitems.subclass  AS subclass,
+                biblioitems.ccode  AS ccode,
+                biblioitems.isbn  AS isbn,
 				biblioitems.classification AS classification
 			FROM issues,items,biblioitems,biblio, itemtypes
 			WHERE issues.borrowernumber  = ?
@@ -1723,23 +1725,6 @@
 	return(\%currentissues);
 }
 
-# Not exported
-sub checkwaiting {
-#Stolen from Main.pm
-# check for reserves waiting
-	my ($env,$dbh,$bornum)=@_;
-	my @itemswaiting;
-	my $sth = $dbh->prepare("select * from reserves where (borrowernumber = ?) and (reserves.found='W') and cancellationdate is NULL");
-	$sth->execute($bornum);
-	my $cnt=0;
-	if (my $data=$sth->fetchrow_hashref) {
-		$itemswaiting[$cnt] =$data;
-		$cnt ++
-	}
-	$sth->finish;
-	return ($cnt,\@itemswaiting);
-}
-
 =head2 renewstatus
 
   $ok = &renewstatus($env, $dbh, $borrowernumber, $itemnumber);





More information about the Koha-cvs mailing list