Bugzilla – Attachment 183751 Details for
Bug 40298
A select2 in a bootstrap modal, like in the patron card batch patron search modal, needs it's parent defined
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
Bug 40298: define select2 parent in patron search modal
Bug-40298-define-select2-parent-in-patron-search-m.patch (text/plain), 1.75 KB, created by
Owen Leonard
on 2025-07-03 12:04:07 UTC
(
hide
)
Description:
Bug 40298: define select2 parent in patron search modal
Filename:
MIME Type:
Creator:
Owen Leonard
Created:
2025-07-03 12:04:07 UTC
Size:
1.75 KB
patch
obsolete
>From 18051c41ebb5ad9d03315fd035cfcf98611ce641 Mon Sep 17 00:00:00 2001 >From: Michael Hafen <michael.hafen@washk12.org> >Date: Wed, 2 Jul 2025 17:56:36 -0600 >Subject: [PATCH] Bug 40298: define select2 parent in patron search modal > >The patron search modal in the patron card creator -> new batch -> >patron search has two select2 modals, sort1 and sort2. If these are not >anchored to the modal they will be anchored to the body element and >appear behind the modal. > >To test, apply the patch and go to Tools -> Patron card creator -> New >-> Card batch. > >- Click "Add patron(s)" >- Test the "Sort 1" and "Sort 2" dropdowns. They should work correctly. > >Signed-off-by: Owen Leonard <oleonard@myacpl.org> >--- > koha-tmpl/intranet-tmpl/prog/en/includes/patron-search.inc | 4 ++-- > 1 file changed, 2 insertions(+), 2 deletions(-) > >diff --git a/koha-tmpl/intranet-tmpl/prog/en/includes/patron-search.inc b/koha-tmpl/intranet-tmpl/prog/en/includes/patron-search.inc >index 85184bdc6aa..80bd155c189 100644 >--- a/koha-tmpl/intranet-tmpl/prog/en/includes/patron-search.inc >+++ b/koha-tmpl/intranet-tmpl/prog/en/includes/patron-search.inc >@@ -292,8 +292,8 @@ > [% END %] > > $(document).on("shown.bs.modal", function(){ >- $('select[name="sort1_filter"]').select2({allowClear:true}); >- $('select[name="sort2_filter"]').select2({allowClear:true}); >+ $('select[name="sort1_filter"]').select2({allowClear:true,dropdownParent:$('#patron_search_modal')}); >+ $('select[name="sort2_filter"]').select2({allowClear:true,dropdownParent:$('#patron_search_modal')}); > }).on("hidden.bs.modal", function(){ > ["sort1_filter", "sort2_filter"].forEach(function(item){ > if( $('select[name=' + item + ']').data("select2") ){ >-- >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 40298
:
183721
| 183751