Lines 104-110
BEGIN {
Link Here
|
104 |
&AddReserve |
104 |
&AddReserve |
105 |
|
105 |
|
106 |
&GetReserve |
106 |
&GetReserve |
107 |
&GetReservesFromBorrowernumber |
|
|
108 |
&GetReservesForBranch |
107 |
&GetReservesForBranch |
109 |
&GetReservesToBranch |
108 |
&GetReservesToBranch |
110 |
&GetReserveCount |
109 |
&GetReserveCount |
Lines 279-318
sub GetReserve {
Link Here
|
279 |
return $sth->fetchrow_hashref(); |
278 |
return $sth->fetchrow_hashref(); |
280 |
} |
279 |
} |
281 |
|
280 |
|
282 |
=head2 GetReservesFromBorrowernumber |
|
|
283 |
|
284 |
$borrowerreserv = GetReservesFromBorrowernumber($borrowernumber,$tatus); |
285 |
|
286 |
TODO :: Descritpion |
287 |
|
288 |
=cut |
289 |
|
290 |
sub GetReservesFromBorrowernumber { |
291 |
my ( $borrowernumber, $status ) = @_; |
292 |
my $dbh = C4::Context->dbh; |
293 |
my $sth; |
294 |
if ($status) { |
295 |
$sth = $dbh->prepare(" |
296 |
SELECT * |
297 |
FROM reserves |
298 |
WHERE borrowernumber=? |
299 |
AND found =? |
300 |
ORDER BY reservedate |
301 |
"); |
302 |
$sth->execute($borrowernumber,$status); |
303 |
} else { |
304 |
$sth = $dbh->prepare(" |
305 |
SELECT * |
306 |
FROM reserves |
307 |
WHERE borrowernumber=? |
308 |
ORDER BY reservedate |
309 |
"); |
310 |
$sth->execute($borrowernumber); |
311 |
} |
312 |
my $data = $sth->fetchall_arrayref({}); |
313 |
return @$data; |
314 |
} |
315 |
|
316 |
=head2 CanBookBeReserved |
281 |
=head2 CanBookBeReserved |
317 |
|
282 |
|
318 |
$canReserve = &CanBookBeReserved($borrowernumber, $biblionumber) |
283 |
$canReserve = &CanBookBeReserved($borrowernumber, $biblionumber) |
319 |
- |
|
|