Bugzilla – Attachment 41010 Details for
Bug 14526
MoveReserve should look at future holds too
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
Bug 14526: MoveReserve should look at future holds too
Bug-14526-MoveReserve-should-look-at-future-holds-.patch (text/plain), 2.35 KB, created by
Marcel de Rooy
on 2015-07-15 13:06:00 UTC
(
hide
)
Description:
Bug 14526: MoveReserve should look at future holds too
Filename:
MIME Type:
Creator:
Marcel de Rooy
Created:
2015-07-15 13:06:00 UTC
Size:
2.35 KB
patch
obsolete
>From b3ce8a83d89c28cbe2b7c509d10b1e78cb4e56ef Mon Sep 17 00:00:00 2001 >From: Marcel de Rooy <m.de.rooy@rijksmuseum.nl> >Date: Mon, 13 Jul 2015 21:55:55 +0200 >Subject: [PATCH] Bug 14526: MoveReserve should look at future holds too >Content-Type: text/plain; charset=utf-8 > >At checkout a hold for the same borrower is considered to be filled. >It is consistent to do the same for holds of the same borrower within >[ConfirmFutureHolds] days (if non-zero). > >This goal is achieved by adjusting the CheckReserves call within >MoveReserve, adding the lookahead parameter. >I used this occasion to revisit other calls of CheckReserves: >- transferbook: no need to add lookahead; a future hold should not block > a transfer; >- CanBookBeIssued: no lookahead; future hold does not block an issue; >- CanBookBeRenewed: idem. >- GetOtherReserves (only used in circ/returns): this call might be a > candidate for lookahead too, but I leave that for another report. It is > in the context of checkin and transfer, not checkout. > >Test plan: >[1] Set ConfirmFutureHolds to zero days. (You may also need to enable > AllowHoldDateInFuture.) >[2] Place a hold with borrower A on biblio X for tomorrow. Also place a hold > with borrower B on X for today. (Use biblio level holds.) >[3] Check out item Y of X to borrower A. Ignore the warning for borrower B > and do not cancel the hold of B (so: confirm checkout). > Verify that X has still two holds. >[4] Check in Y (without confirming a hold). >[5] Enable ConfirmFutureHolds, say 2 days. >[6] Check out Y to A again. Ignore the warning for B (no cancel). Verify that > X now only has one hold for borrower B (the hold for A was filled). >--- > C4/Reserves.pm | 3 ++- > 1 file changed, 2 insertions(+), 1 deletion(-) > >diff --git a/C4/Reserves.pm b/C4/Reserves.pm >index 6252b86..9d4c8c3 100644 >--- a/C4/Reserves.pm >+++ b/C4/Reserves.pm >@@ -2218,7 +2218,8 @@ If $cancelreserve boolean is set to true, it will remove existing reserve > sub MoveReserve { > my ( $itemnumber, $borrowernumber, $cancelreserve ) = @_; > >- my ( $restype, $res, $all_reserves ) = CheckReserves( $itemnumber ); >+ my $lookahead= C4::Context->preference('ConfirmFutureHolds'); #number of days to look for future holds >+ my ( $restype, $res, $all_reserves ) = CheckReserves( $itemnumber, undef, $lookahead ); > return unless $res; > > my $biblionumber = $res->{biblionumber}; >-- >1.7.10.4
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Diff
View Attachment As Raw
Actions:
View
|
Diff
|
Splinter Review
Attachments on
bug 14526
:
41010
|
41011
|
41241
|
41807
|
41808
|
42014
|
42100
|
42101
|
42102
|
42144
|
42150
|
42151
|
42152