Bugzilla – Attachment 183227 Details for
Bug 40122
'Holds to pull' library filters don't work if library name contains parenthesis
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
Bug 40122: Dont attempt regex search for select dropdowns
Bug-40122-Dont-attempt-regex-search-for-select-dro.patch (text/plain), 2.02 KB, created by
David Nind
on 2025-06-13 08:16:35 UTC
(
hide
)
Description:
Bug 40122: Dont attempt regex search for select dropdowns
Filename:
MIME Type:
Creator:
David Nind
Created:
2025-06-13 08:16:35 UTC
Size:
2.02 KB
patch
obsolete
>From 1848d49746185f90407c3c1a791dba69255e2c7b Mon Sep 17 00:00:00 2001 >From: Pedro Amorim <pedro.amorim@openfifth.co.uk> >Date: Wed, 11 Jun 2025 15:53:56 +0000 >Subject: [PATCH] Bug 40122: Dont attempt regex search for select dropdowns > >Test plan: >1) Place a hold (next available) to biblio 76 and 437: >http://localhost:8081/cgi-bin/koha/catalogue/detail.pl?biblionumber=76 >http://localhost:8081/cgi-bin/koha/catalogue/detail.pl?biblionumber=437 >2) Edit 'Centerville' library name to 'Centerville (CPL)' >3) Visit the 'holds to pull' page: >http://localhost:8081/cgi-bin/koha/circ/pendingreserves.pl >4) Try to filter for 'Centerville (CPL)'. Notice the filtering returns nothing. >5) Apply patches. Repeat test plan. Notice 'Centerville (CPL)' filtering now works. >--- > koha-tmpl/intranet-tmpl/prog/js/datatables.js | 10 +++++++--- > 1 file changed, 7 insertions(+), 3 deletions(-) > >diff --git a/koha-tmpl/intranet-tmpl/prog/js/datatables.js b/koha-tmpl/intranet-tmpl/prog/js/datatables.js >index 8149806db9..bdfe317dda 100644 >--- a/koha-tmpl/intranet-tmpl/prog/js/datatables.js >+++ b/koha-tmpl/intranet-tmpl/prog/js/datatables.js >@@ -1128,8 +1128,12 @@ function _dt_add_delay_filters(table_dt, table_node) { > let col_input_search = DataTable.util.debounce(function (i, val) { > table_dt.column(i).search(val).draw(); > }, delay_ms); >- let col_select_search = DataTable.util.debounce(function (i, val) { >- table_dt.column(i).search(val, true, false).draw(); >+ let col_select_search = DataTable.util.debounce(function ( >+ i, >+ val, >+ regex_search = true >+ ) { >+ table_dt.column(i).search(val, regex_search, false).draw(); > }, delay_ms); > > $(table_node) >@@ -1148,7 +1152,7 @@ function _dt_add_delay_filters(table_dt, table_node) { > .find("select") > .unbind() > .bind("keyup change", function () { >- col_select_search(i, this.value); >+ col_select_search(i, this.value, false); > }); > }); > } >-- >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 40122
:
183171
|
183172
|
183173
|
183227
|
183319