From 65890ab4e82c3c358366c6ce4d996ad83576bb0e Mon Sep 17 00:00:00 2001 From: Fridolin Somers Date: Wed, 6 Aug 2025 10:18:06 +0200 Subject: [PATCH] Bug 39423: Fix column checkboxes in batch item modification hide incorrect columns In batch item modification, unchecking any column hides the previous column. This is caused by new HTML in table header : This patch fixed by adding ".dt-column-title" to function guess_nb_cols(). Test plan : 1) Go to batch item modification 2) In "Show/hide columns:" click on "Home library" column => Check correct column is hidden 3) Go to another batch item modification => Check column "Home library" is hidden (from cookie storage) Signed-off-by: Emmi Takkinen --- koha-tmpl/intranet-tmpl/prog/js/pages/batchMod.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/koha-tmpl/intranet-tmpl/prog/js/pages/batchMod.js b/koha-tmpl/intranet-tmpl/prog/js/pages/batchMod.js index ed51892fd3..ac425b46d5 100644 --- a/koha-tmpl/intranet-tmpl/prog/js/pages/batchMod.js +++ b/koha-tmpl/intranet-tmpl/prog/js/pages/batchMod.js @@ -5,7 +5,7 @@ date.setTime(date.getTime() + 365 * 24 * 60 * 60 * 1000); function guess_nb_cols() { // This is a bit ugly, we are trying to know if there are checkboxes in the first column of the table - if ($("#itemst tr:first th:first").html() == "") { + if ($("#itemst tr:first th:first .dt-column-title").html() == "") { // First header is empty, it's a checkbox return 3; } else { -- 2.34.1