Bugzilla – Attachment 139495 Details for
Bug 31112
Able to renew checkout when the number of holds exceeds available number of items
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
Bug 31112: (QA follow-up) Fetch patrons with reserves
Bug-31112-QA-follow-up-Fetch-patrons-with-reserves.patch (text/plain), 1.19 KB, created by
Nick Clemens (kidclamp)
on 2022-08-19 13:43:16 UTC
(
hide
)
Description:
Bug 31112: (QA follow-up) Fetch patrons with reserves
Filename:
MIME Type:
Creator:
Nick Clemens (kidclamp)
Created:
2022-08-19 13:43:16 UTC
Size:
1.19 KB
patch
obsolete
>From 6c17f6c6a806435dbbf570e855d13a1dbfa434fc Mon Sep 17 00:00:00 2001 >From: Nick Clemens <nick@bywatersolutions.com> >Date: Fri, 19 Aug 2022 13:23:05 +0000 >Subject: [PATCH] Bug 31112: (QA follow-up) Fetch patrons with reserves > >Previously we fetched all in a single call using biblionumbers > >Fetching each individually could be a performance hit on systems >with large numbers of holds > >Signed-off-by: Nick Clemens <nick@bywatersolutions.com> >--- > C4/Circulation.pm | 5 ++++- > 1 file changed, 4 insertions(+), 1 deletion(-) > >diff --git a/C4/Circulation.pm b/C4/Circulation.pm >index fd006ec2e1..606d83940b 100644 >--- a/C4/Circulation.pm >+++ b/C4/Circulation.pm >@@ -2949,7 +2949,10 @@ sub CanBookBeRenewed { > ) > { > my $biblio = Koha::Biblios->find($item->biblionumber); >- my @possible_holds = $biblio->current_holds->unfilled->search({non_priority => 0})->as_list; >+ my @possible_holds = $biblio->current_holds->unfilled->search( >+ {non_priority => 0}, >+ { prefetch => 'patron' } >+ )->as_list; > > # Get all other items that could possibly fill reserves > # FIXME We could join reserves (or more tables) here to eliminate some checks later >-- >2.30.2
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 31112
:
137826
|
137827
|
137828
|
137856
|
137857
|
137858
|
139492
|
139493
|
139494
|
139495
|
139622
|
139623
|
139729
|
139730
|
139731
|
139732
|
139733
|
139734
|
139735