Bugzilla – Attachment 192544 Details for
Bug 41445
Wrong info about holds selection after hold suspending
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
Bug 41445: Fix hold actions incorrectly toggling select-all checkbox state
Bug-41445-Fix-hold-actions-incorrectly-toggling-se.patch (text/plain), 3.26 KB, created by
Lawrence O'Regan-Lloyd
on 2026-02-05 19:45:31 UTC
(
hide
)
Description:
Bug 41445: Fix hold actions incorrectly toggling select-all checkbox state
Filename:
MIME Type:
Creator:
Lawrence O'Regan-Lloyd
Created:
2026-02-05 19:45:31 UTC
Size:
3.26 KB
patch
obsolete
>From 3a06091ee9fc17e6287aa9edd979f3a4c998dcbb Mon Sep 17 00:00:00 2001 >From: Lawrence O'Regan-Lloyd <loreganlloyd@clamsnet.org> >Date: Fri, 30 Jan 2026 16:51:48 -0500 >Subject: [PATCH] Bug 41445: Fix hold actions incorrectly toggling select-all > checkbox state > > Replace .click() on select_hold_all with explicit .prop("checked", false) > to prevent suspend, resume, cancel, and group hold actions from > incorrectly checking the select-all checkbox and showing a wrong > selected holds count. > > Test plan: > 1. Go to a patron with 2 or more active holds > 2. Navigate to Details -> Holds tab > 3. Click Suspend on a single hold and confirm > 4. Verify the select-all checkbox remains unchecked > 5. Verify the selected holds count does not appear > 6. Repeat steps 3-5 from the Check out -> Holds tab > 7. Repeat using Resume, Cancel, and Group hold actions > > Sponsored-by: CLAMS >--- > koha-tmpl/intranet-tmpl/prog/js/holds.js | 16 ++++++++++++---- > 1 file changed, 12 insertions(+), 4 deletions(-) > >diff --git a/koha-tmpl/intranet-tmpl/prog/js/holds.js b/koha-tmpl/intranet-tmpl/prog/js/holds.js >index 5e6537fa72..a9d4c4a0b8 100644 >--- a/koha-tmpl/intranet-tmpl/prog/js/holds.js >+++ b/koha-tmpl/intranet-tmpl/prog/js/holds.js >@@ -126,7 +126,9 @@ $(document).ready(function () { > url: "/api/v1/holds/" + encodeURIComponent(hold_id) + "/suspension", > }).done(function () { > if ($(".select_hold_all").prop("checked")) { >- $(".select_hold_all").click(); >+ $(".select_hold_all").prop("checked", false); >+ $(".holds_table .select_hold").prop("checked", false); >+ updateSelectedHoldsButtonCounters(); > } > }); > } >@@ -659,7 +661,9 @@ $(document).ready(function () { > $("#suspend-modal-until").flatpickr().clear(); // clean the input > } > $("#suspend-modal").modal("hide"); >- $(".select_hold_all").click(); >+ $(".select_hold_all").prop("checked", false); >+ $(".holds_table .select_hold").prop("checked", false); >+ updateSelectedHoldsButtonCounters(); > }); > } catch (error) { > if (error.status === 404) { >@@ -1209,7 +1213,9 @@ $(document).ready(function () { > .done(function () { > $("#cancelModal").modal("hide"); > if ($(".select_hold_all").prop("checked")) { >- $(".select_hold_all").click(); >+ $(".select_hold_all").prop("checked", false); >+ $(".holds_table .select_hold").prop("checked", false); >+ updateSelectedHoldsButtonCounters(); > } > }); > }); >@@ -1254,7 +1260,9 @@ $(document).ready(function () { > }) > .done(function () { > $("#group-modal").modal("hide"); >- $(".select_hold_all").click(); >+ $(".select_hold_all").prop("checked", false); >+ $(".holds_table .select_hold").prop("checked", false); >+ updateSelectedHoldsButtonCounters(); > }); > } catch (error) { > if (error.status === 404) { >-- >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 41445
:
192544
|
192548