[Koha-cvs] CVS: koha updateitem.pl,1.5,1.6
Andrew Arensburger
arensb at users.sourceforge.net
Sat Oct 5 11:47:39 CEST 2002
Update of /cvsroot/koha/koha
In directory usw-pr-cvs1:/tmp/cvs-serv20183
Modified Files:
updateitem.pl
Log Message:
Merged with arensb-context branch: use C4::Context->dbh instead of
&C4Connect, and generally prefer C4::Context over C4::Database.
Index: updateitem.pl
===================================================================
RCS file: /cvsroot/koha/koha/updateitem.pl,v
retrieving revision 1.5
retrieving revision 1.6
diff -C2 -r1.5 -r1.6
*** updateitem.pl 20 Sep 2002 13:01:51 -0000 1.5
--- updateitem.pl 5 Oct 2002 09:47:37 -0000 1.6
***************
*** 19,25 ****
# Suite 330, Boston, MA 02111-1307 USA
- use C4::Database;
- use CGI;
use strict;
use C4::Acquisitions;
use C4::Biblio;
--- 19,25 ----
# Suite 330, Boston, MA 02111-1307 USA
use strict;
+ use CGI;
+ use C4::Context;
use C4::Acquisitions;
use C4::Biblio;
***************
*** 88,92 ****
});
if ($lost ==1){
! my $dbh=C4Connect;
my $sth=$dbh->prepare("Select * from issues where (itemnumber='$itemnum') and (returndate is null)");
$sth->execute;
--- 88,92 ----
});
if ($lost ==1){
! my $dbh = C4::Context->dbh;
my $sth=$dbh->prepare("Select * from issues where (itemnumber='$itemnum') and (returndate is null)");
$sth->execute;
***************
*** 115,119 ****
# print "marking cancelled";
#need to check if it is on reserve or issued
! my $dbh=C4Connect;
my $flag=0;
my ($resbor,$resrec)=C4::Circulation::Circ2::checkreserve($env,$dbh,$itemnum);
--- 115,119 ----
# print "marking cancelled";
#need to check if it is on reserve or issued
! my $dbh = C4::Context->dbh;
my $flag=0;
my ($resbor,$resrec)=C4::Circulation::Circ2::checkreserve($env,$dbh,$itemnum);
***************
*** 133,137 ****
}
$sth->finish;
- $dbh->disconnect;
if ($flag == 1){
my $url=$input->self_url;
--- 133,136 ----
More information about the Koha-cvs
mailing list