Bugzilla – Attachment 154140 Details for
Bug 29750
Reserves.pm should check patron category hold policies when finding a reserve for an item
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
Bug 29750: Reserves.pm should check if a patron is eligible to reserve and item before confirming the reserve
Bug-29750-Reservespm-should-check-if-a-patron-is-e.patch (text/plain), 1.96 KB, created by
Alex Buckley
on 2023-08-01 23:21:18 UTC
(
hide
)
Description:
Bug 29750: Reserves.pm should check if a patron is eligible to reserve and item before confirming the reserve
Filename:
MIME Type:
Creator:
Alex Buckley
Created:
2023-08-01 23:21:18 UTC
Size:
1.96 KB
patch
obsolete
>From 1ace1fc3015bb1d8e0c844f7c80529a2150ccaa2 Mon Sep 17 00:00:00 2001 >From: Alex Buckley <alexbuckley@catalyst.net.nz> >Date: Thu, 9 Dec 2021 13:50:41 +0000 >Subject: [PATCH] Bug 29750: Reserves.pm should check if a patron is eligible > to reserve and item before confirming the reserve > >Test plan: >1. Create two patrons, with the following patron categories: >- Patron A -> Patron >- Patron B -> Student >2. Create two items attached to a single biblio record: >- Book >- Continuing resource >3. Create the following circ rules: >Patron category, item type, Holds allowed (total), Holds allowed >(daily), Holds per record (count) >- Patron, Book, 0, 0, 0 >- Student, Book, 1, 1, 1 >- All, Continuing resources, 1, 1, 1 >4. Place a title level hold on the biblio for patron A >5. Place a title level hold on the biblio for patron B >6. Checkin the Book and notice you are prompted to confirm the hold >by Patron A - even though according to circ rules they cannot reserve Books >7. Apply patch and restart services >9. Checkin the Book, and notice you're prompted to confirm the hold >by Patron B > >Sponsored-By: Catalyst IT >--- > C4/Reserves.pm | 1 + > 1 file changed, 1 insertion(+) > >diff --git a/C4/Reserves.pm b/C4/Reserves.pm >index 69f81df6e1b..fc00b4b191a 100644 >--- a/C4/Reserves.pm >+++ b/C4/Reserves.pm >@@ -950,6 +950,7 @@ sub CheckReserves { > next if ( ($hold_fulfillment_policy eq 'homebranch') && ($res->{branchcode} ne $item->$hold_fulfillment_policy) ); > next if ( ($hold_fulfillment_policy eq 'holdingbranch') && ($res->{branchcode} ne $item->$hold_fulfillment_policy) ); > next unless $item->can_be_transferred( { to => Koha::Libraries->find( $res->{branchcode} ) } ); >+ next if (CanItemBeReserved( $patron, $item, $res->{branchcode}, { ignore_hold_counts => 1 } )->{status} ne 'OK'); > $priority = $res->{'priority'}; > $highest = $res; > last if $local_hold_match; >-- >2.20.1
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 29750
:
128858
|
128859
|
154140
|
154141
|
154159
|
154160