Bugzilla – Attachment 120002 Details for
Bug 27811
Manage patrons fines and fees (updatecharges) subpermissions shows links/buttons that cannot be accessed
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
Bug 27811: Hide payment buttons if not enough permission
Bug-27811-Hide-payment-buttons-if-not-enough-permi.patch (text/plain), 2.09 KB, created by
Jonathan Druart
on 2021-04-22 12:25:48 UTC
(
hide
)
Description:
Bug 27811: Hide payment buttons if not enough permission
Filename:
MIME Type:
Creator:
Jonathan Druart
Created:
2021-04-22 12:25:48 UTC
Size:
2.09 KB
patch
obsolete
>From 0601ed06d6e0e201d6f0d224cdc4414cfc1d8d86 Mon Sep 17 00:00:00 2001 >From: Jonathan Druart <jonathan.druart@bugs.koha-community.org> >Date: Thu, 22 Apr 2021 14:20:27 +0200 >Subject: [PATCH] Bug 27811: Hide payment buttons if not enough permission > >If the logged in librarian does not have the updatecharges > >remaining_permissions subpermission, we should hide the 2 "Make payment" >and "Pay all fines" button from the patron detail/circ page. > >Test plan: >1 - Grant an account circulation/staffaccess permissions and any subpermissions in updatechagres but NOT 'remaining_permissions' >2 - Add some charges to a patron account >3 - Sign in with the account created in #1 >4 - Bring up the patron you added charges to >=> The two buttons are not displayed >--- > koha-tmpl/intranet-tmpl/prog/en/includes/blocked-fines.inc | 6 ++++-- > 1 file changed, 4 insertions(+), 2 deletions(-) > >diff --git a/koha-tmpl/intranet-tmpl/prog/en/includes/blocked-fines.inc b/koha-tmpl/intranet-tmpl/prog/en/includes/blocked-fines.inc >index ccb5ed2df6..c9bb3712fe 100644 >--- a/koha-tmpl/intranet-tmpl/prog/en/includes/blocked-fines.inc >+++ b/koha-tmpl/intranet-tmpl/prog/en/includes/blocked-fines.inc >@@ -7,7 +7,9 @@ > [% IF !Koha.Preference('AllowFineOverride') && NoIssuesCharge && fines > NoIssuesCharge %] > <span class="circ-hlt">Checkouts are BLOCKED because fine balance is OVER THE LIMIT.</span> > [% END %] >- <a href="/cgi-bin/koha/members/pay.pl?borrowernumber=[% patron.borrowernumber | uri %]" class="btn btn-default btn-xs" >Make payment</a> >- <a href="/cgi-bin/koha/members/paycollect.pl?borrowernumber=[% patron.borrowernumber | uri %]" class="btn btn-default btn-xs" >Pay all fines</a></li> >+ [% IF CAN_user_updatecharges_remaining_permissions %] >+ <a href="/cgi-bin/koha/members/pay.pl?borrowernumber=[% patron.borrowernumber | uri %]" class="btn btn-default btn-xs" >Make payment</a> >+ <a href="/cgi-bin/koha/members/paycollect.pl?borrowernumber=[% patron.borrowernumber | uri %]" class="btn btn-default btn-xs" >Pay all fines</a></li> >+ [% END %] > </li> > [% END %] >-- >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 27811
:
120002
|
120003
|
120303
|
120304