Bugzilla – Attachment 195235 Details for
Bug 41573
Tidy kohaTable block - patron_lists
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
Bug 41573: Tidy kohaTable - patron_lists/patron-lists-tab.tt
Bug-41573-Tidy-kohaTable---patronlistspatron-lists.patch (text/plain), 3.04 KB, created by
Lucas Gass (lukeg)
on 2026-03-12 21:15:37 UTC
(
hide
)
Description:
Bug 41573: Tidy kohaTable - patron_lists/patron-lists-tab.tt
Filename:
MIME Type:
Creator:
Lucas Gass (lukeg)
Created:
2026-03-12 21:15:37 UTC
Size:
3.04 KB
patch
obsolete
>From 1aaaff39ebb24d416d504a0df2c2cec948d3e143 Mon Sep 17 00:00:00 2001 >From: Jonathan Druart <jonathan.druart@bugs.koha-community.org> >Date: Thu, 8 Jan 2026 14:17:56 +0100 >Subject: [PATCH] Bug 41573: Tidy kohaTable - patron_lists/patron-lists-tab.tt > >Signed-off-by: Paul Derscheid <paul.derscheid@lmscloud.de> >Signed-off-by: Lucas Gass <lucas@bywatersolutions.com> >--- > .../en/modules/patron_lists/patron-lists-tab.tt | 16 ++++++++++++---- > 1 file changed, 12 insertions(+), 4 deletions(-) > >diff --git a/koha-tmpl/intranet-tmpl/prog/en/modules/patron_lists/patron-lists-tab.tt b/koha-tmpl/intranet-tmpl/prog/en/modules/patron_lists/patron-lists-tab.tt >index 624bb9e37c4..5bbbdbaa75c 100644 >--- a/koha-tmpl/intranet-tmpl/prog/en/modules/patron_lists/patron-lists-tab.tt >+++ b/koha-tmpl/intranet-tmpl/prog/en/modules/patron_lists/patron-lists-tab.tt >@@ -122,6 +122,14 @@ > [% ELSIF !in_lists && CAN_user_tools_manage_patron_lists %] > <p>Patron is not on any list. <a href="/cgi-bin/koha/patron_lists/add-modify.pl">Create a new patron list</a>.</p> > [% END %] >+<script> >+ const patron_id = "[% borrowernumber | html %]"; >+ const cardnumber = "[% cardnumber | html %]"; >+ addPermissions({ >+ CAN_user_tools_manage_patron_lists: [% CAN_user_tools_manage_patron_lists ? 1 : 0 | html %], >+ }); >+</script> >+ > <script> > var patron_lists_dt_params = { > sPaginationType: "full", >@@ -129,12 +137,12 @@ > $("#table_listnopatron").kohaTable(patron_lists_dt_params); > $("#table_inlists").kohaTable(patron_lists_dt_params); > >- [% IF CAN_user_tools_manage_patron_lists %] >+ if (permissions.CAN_user_tools_manage_patron_lists){ > function addToList() { > var list_id = $("#add_to_patron_list_id_select").val(); > $('#pat_lists_panel').text(_("Loading...")); > $("body").css("cursor", "progress"); >- $('#pat_lists_panel').load('/cgi-bin/koha/patron_lists/patron-lists-tab.pl?borrowernumber=[% borrowernumber | html %]&patron_list_id=' + list_id + '&patrons_to_add=[% cardnumber | html %]', function() { >+ $('#pat_lists_panel').load(`/cgi-bin/koha/patron_lists/patron-lists-tab.pl?borrowernumber=${patron_id}&patron_list_id=${list_id}&patrons_to_add=${cardnumber}, function() { > $("body").css("cursor", "default"); > }); > >@@ -144,11 +152,11 @@ > function removeFromList( list_id, patron_list_patron_id ) { > $('#pat_lists_panel').text(_("Loading...")); > $("body").css("cursor", "progress"); >- $('#pat_lists_panel').load('/cgi-bin/koha/patron_lists/patron-lists-tab.pl?borrowernumber=[% borrowernumber | html %]&patron_list_id=' + list_id + '&patrons_to_remove=' + patron_list_patron_id, function() { >+ $('#pat_lists_panel').load(`/cgi-bin/koha/patron_lists/patron-lists-tab.pl?borrowernumber=${patron_id}&patron_list_id=${list_id}&patrons_to_remove=${patron_list_patron_id}`, function() { > $("body").css("cursor", "default"); > }); > > return false; > } >- [% END %] >+ } > </script> >-- >2.39.5
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 41573
:
191139
|
191140
|
191141
|
191142
|
194733
|
194734
|
194735
|
194736
|
194737
|
194738
|
194746
|
194747
|
194748
|
194749
|
194750
|
194751
|
195158
|
195233
|
195234
| 195235 |
195236
|
195237
|
195238