Bugzilla – Attachment 114209 Details for
Bug 15448
Placing hold on specific items doesn't enforce OpacHiddenItems
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
Bug 15448: (follow-up) Fetch the patron category once
Bug-15448-follow-up-Fetch-the-patron-category-once.patch (text/plain), 1.53 KB, created by
Kyle M Hall (khall)
on 2020-12-04 18:27:30 UTC
(
hide
)
Description:
Bug 15448: (follow-up) Fetch the patron category once
Filename:
MIME Type:
Creator:
Kyle M Hall (khall)
Created:
2020-12-04 18:27:30 UTC
Size:
1.53 KB
patch
obsolete
>From 6b3d5a1f5c2891720b2c5f5493408367b19edb9e Mon Sep 17 00:00:00 2001 >From: Tomas Cohen Arazi <tomascohen@theke.io> >Date: Fri, 4 Dec 2020 08:33:43 -0300 >Subject: [PATCH] Bug 15448: (follow-up) Fetch the patron category once > >Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com> >--- > opac/opac-reserve.pl | 6 +++--- > 1 file changed, 3 insertions(+), 3 deletions(-) > >diff --git a/opac/opac-reserve.pl b/opac/opac-reserve.pl >index 139d7101af..f893debfb1 100755 >--- a/opac/opac-reserve.pl >+++ b/opac/opac-reserve.pl >@@ -70,7 +70,7 @@ for ( C4::Context->preference("OPACShowHoldQueueDetails") ) { > m/priority/ and $show_priority = 1; > } > >-my $patron = Koha::Patrons->find( $borrowernumber ); >+my $patron = Koha::Patrons->find( $borrowernumber, { prefetch => ['categorycode'] } ); > my $category = $patron->category; > # no OpacHiddenItems rules used if category is excepted > my $item_hide_rules = >@@ -88,7 +88,7 @@ unless ( $can_place_hold_if_available_at_pickup ) { > } > > # check if this user can place a reserve, -1 means use sys pref, 0 means dont block, 1 means block >-if ( $patron->category->effective_BlockExpiredPatronOpacActions ) { >+if ( $category->effective_BlockExpiredPatronOpacActions ) { > > if ( $patron->is_expired ) { > >@@ -100,7 +100,7 @@ if ( $patron->category->effective_BlockExpiredPatronOpacActions ) { > } > > # Pass through any reserve charge >-my $reservefee = $patron->category->reservefee; >+my $reservefee = $category->reservefee; > if ( $reservefee > 0){ > $template->param( RESERVE_CHARGE => $reservefee); > } >-- >2.24.1 (Apple Git-126)
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 15448
:
46100
|
113875
|
113876
|
114188
|
114189
|
114191
|
114193
|
114194
|
114208
|
114209
|
114263
|
114264
|
114578
|
115133
|
115134