[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Koha-cvs] CVS: koha/C4 Reserves2.pm,1.5.2.2,1.5.2.3
From: |
Paul POULAIN |
Subject: |
[Koha-cvs] CVS: koha/C4 Reserves2.pm,1.5.2.2,1.5.2.3 |
Date: |
Tue, 02 Jul 2002 08:47:18 -0700 |
Update of /cvsroot/koha/koha/C4
In directory usw-pr-cvs1:/tmp/cvs-serv14542/C4
Modified Files:
Tag: rel-1-2
Reserves2.pm
Log Message:
Merge from 1.2 and main branches. Only cosmetic changes (spaces)
Index: Reserves2.pm
===================================================================
RCS file: /cvsroot/koha/koha/C4/Reserves2.pm,v
retrieving revision 1.5.2.2
retrieving revision 1.5.2.3
diff -C2 -r1.5.2.2 -r1.5.2.3
*** Reserves2.pm 18 May 2002 10:21:51 -0000 1.5.2.2
--- Reserves2.pm 2 Jul 2002 15:47:16 -0000 1.5.2.3
***************
*** 20,42 ****
my ($bib,$bor)address@hidden;
my $dbh=C4Connect;
! my $query="Select *,reserves.branchcode,biblio.title as btitle
! from reserves,borrowers,biblio ";
if ($bib ne ''){
if ($bor ne ''){
! $query=$query." where reserves.biblionumber=$bib and
! reserves.borrowernumber=borrowers.borrowernumber and
! biblio.biblionumber=$bib and cancellationdate is NULL and
! (found <> 'F' or found is NULL)";
! } else {
! $query=$query." where reserves.borrowernumber=borrowers.borrowernumber
! and biblio.biblionumber=$bib and reserves.biblionumber=$bib
! and cancellationdate is NULL and
! (found <> 'F' or found is NULL)";
! }
} else {
! $query=$query." where borrowers.borrowernumber=$bor and
! reserves.borrowernumber=borrowers.borrowernumber and reserves.biblionumber
! =biblio.biblionumber and cancellationdate is NULL and
! (found <> 'F' or found is NULL)";
}
$query.=" order by priority";
--- 20,47 ----
my ($bib,$bor)address@hidden;
my $dbh=C4Connect;
! my $query="SELECT *,reserves.branchcode,biblio.title AS btitle
! FROM reserves,borrowers,biblio ";
if ($bib ne ''){
if ($bor ne ''){
! $query .= " where reserves.biblionumber = $bib
! and borrowers.borrowernumber = $bor
! and reserves.borrowernumber =
borrowers.borrowernumber
! and biblio.biblionumber = $bib
! and cancellationdate is NULL
! and (found <> 'F' or found is NULL)";
! } else {
! $query .= " where reserves.borrowernumber = borrowers.borrowernumber
! and biblio.biblionumber = $bib
! and reserves.biblionumber = $bib
! and cancellationdate is NULL
! and (found <> 'F' or found is NULL)";
! }
} else {
! $query .= " where borrowers.borrowernumber = $bor
! and reserves.borrowernumber = borrowers.borrowernumber
! and reserves.biblionumber = biblio.biblionumber
! and cancellationdate is NULL and
! (found <> 'F' or found is NULL)";
! }
}
$query.=" order by priority";
***************
*** 59,73 ****
my $dbh=C4Connect;
$bibitem=$dbh->quote($bibitem);
! my $query="Select * from reserves
! left join reserveconstraints on
! reserves.biblionumber=reserveconstraints.biblionumber
! where
! reserves.biblionumber=$biblio and
! ((reserveconstraints.biblioitemnumber=$bibitem
! and reserves.borrowernumber=reserveconstraints.borrowernumber
! and reserves.reservedate=reserveconstraints.reservedate)
! or reserves.constrainttype='a')
! and reserves.cancellationdate is NULL
! and (reserves.found <> 'F' or reserves.found is NULL)";
# print $query;
my $sth=$dbh->prepare($query);
--- 64,87 ----
my $dbh=C4Connect;
$bibitem=$dbh->quote($bibitem);
! my $query = "SELECT reserves.biblionumber AS biblionumber,
! reserves.borrowernumber AS borrowernumber,
! reserves.reservedate AS reservedate,
! reserves.branchcode AS branchcode,
! reserves.cancellationdate AS
cancellationdate,
! reserves.found AS found,
! reserves.reservenotes AS reservenotes,
! reserves.priority AS priority,
! reserves.timestamp AS timestamp,
! reserveconstraints.biblioitemnumber AS
biblioitemnumber,
! reserves.itemnumber AS itemnumber
! FROM reserves LEFT JOIN reserveconstraints
! ON reserves.biblionumber = reserveconstraints.biblionumber
! WHERE reserves.biblionumber = $biblio
! AND ( ( reserveconstraints.biblioitemnumber = $bibitem
! AND reserves.borrowernumber =
reserveconstraints.borrowernumber
! AND reserves.reservedate
=reserveconstraints.reservedate )
! OR reserves.constrainttype='a' )
! AND reserves.cancellationdate is NULL
! AND (reserves.found <> 'F' or reserves.found is NULL)";
# print $query;
my $sth=$dbh->prepare($query);
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- [Koha-cvs] CVS: koha/C4 Reserves2.pm,1.5.2.2,1.5.2.3,
Paul POULAIN <=