[Bug 43991] New: Pickup location change modal is unusable on narrow OPAC screens
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=43991 Bug ID: 43991 Summary: Pickup location change modal is unusable on narrow OPAC screens Initiative type: --- Sponsorship --- status: Product: Koha Version: Main Hardware: All OS: All Status: NEW Severity: normal Priority: P5 - low Component: OPAC Assignee: oleonard@myacpl.org Reporter: martin.renvoize@openfifth.co.uk QA Contact: testopia@bugs.koha-community.org Target Milestone: --- On the OPAC summary page (opac-user.pl), on a narrow/mobile viewport, pressing "Change" next to a hold's pickup location greys out the page but shows no dialog. The patron cannot choose a library or dismiss the modal, and is stuck unless they switch the browser to desktop mode. On desktop the modal displays correctly. Cause: the per-hold change pickup modal (#changePickup<reserve_id>) is rendered inside the "Pickup location" table cell of the holds table (includes/holds-table.inc). On narrow screens DataTables Responsive hides that column (td.dtr-hidden, display:none) and copies its markup into the expanded child row, which leaves two elements with the same id. Bootstrap resolves data-bs-target to the first match, which is the modal inside the hidden cell. The backdrop (appended to body) is shown, but the dialog has no layout box. Test plan: 1. Enable OPACAllowUserToChangeBranch (e.g. "pending,intransit,suspended") 2. Place a hold for a patron 3. Log in to the OPAC as that patron at a narrow viewport (e.g. 375px wide, browser devtools device emulation) and open the Holds tab 4. Expand the hold row with the "+" control and press "Change" next to the pickup location 5. Note the page greys out and no dialog is visible 6. Apply the patch and reload; repeat 7. Confirm the dialog is visible, pick another library, Save, and confirm the pickup location changes 8. Repeat at desktop width and confirm the modal still works -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=43991 --- Comment #1 from Martin Renvoize (ashimema) <martin.renvoize@openfifth.co.uk> --- Created attachment 210392 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=210392&action=edit Bug 43991: Pickup location change modal is unusable on narrow OPAC screens On the OPAC summary page, the "Change" pickup location modal for each hold is rendered inside the "Pickup location" table cell of the holds table. On narrow viewports DataTables Responsive hides that column (td.dtr-hidden, display:none) and copies its markup into the expanded child row. This leaves two elements with the same id: the real modal in the hidden cell, and a dead copy in the child row. Bootstrap resolves data-bs-target="#changePickupN" to the first match, the one inside the hidden cell. The backdrop (appended to <body>) is shown, but the dialog has no layout box, so the patron sees a greyed out page with no way to pick a library or dismiss the modal. Render the modals after the table instead, in their own loop. The "Change" button keeps working in the child row because it only needs the id to be unique and reachable from <body>. This matches how the suspend hold modal is already handled on the same page. To test: 1. Enable OPACAllowUserToChangeBranch (e.g. "pending,intransit,suspended") 2. Place a hold for a patron whose hold can be changed to another pickup library 3. Log in to the OPAC as that patron at a narrow viewport (e.g. browser devtools device emulation, 375px wide), and open the Holds tab 4. Expand the hold row with the "+" control and press "Change" next to the pickup location 5. Without the patch: the page greys out and no dialog is visible 6. Apply the patch and reload; repeat 7. Confirm the dialog is visible, pick another library, press Save and confirm the pickup location changes 8. Repeat at desktop width and confirm the modal still works there 9. Confirm the page contains no duplicate ids: in the console run document.querySelectorAll('[id="changePickup1"]').length and expect 1 Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com> -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=43991 Martin Renvoize (ashimema) <martin.renvoize@openfifth.co.uk> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|NEW |Needs Signoff Assignee|oleonard@myacpl.org |martin.renvoize@openfifth.c | |o.uk -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=43991 Martin Renvoize (ashimema) <martin.renvoize@openfifth.co.uk> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |sally.healey@cheshireshared | |services.gov.uk -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=43991 Martin Renvoize (ashimema) <martin.renvoize@openfifth.co.uk> changed: What |Removed |Added ---------------------------------------------------------------------------- Severity|normal |major -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=43991 Martin Renvoize (ashimema) <martin.renvoize@openfifth.co.uk> changed: What |Removed |Added ---------------------------------------------------------------------------- Patch complexity|--- |Small patch -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=43991 David Nind <david@davidnind.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|Needs Signoff |Signed Off -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=43991 David Nind <david@davidnind.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Attachment #210392|0 |1 is obsolete| | -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=43991 --- Comment #2 from David Nind <david@davidnind.com> --- Created attachment 210561 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=210561&action=edit Bug 43991: Pickup location change modal is unusable on narrow OPAC screens On the OPAC summary page, the "Change" pickup location modal for each hold is rendered inside the "Pickup location" table cell of the holds table. On narrow viewports DataTables Responsive hides that column (td.dtr-hidden, display:none) and copies its markup into the expanded child row. This leaves two elements with the same id: the real modal in the hidden cell, and a dead copy in the child row. Bootstrap resolves data-bs-target="#changePickupN" to the first match, the one inside the hidden cell. The backdrop (appended to <body>) is shown, but the dialog has no layout box, so the patron sees a greyed out page with no way to pick a library or dismiss the modal. Render the modals after the table instead, in their own loop. The "Change" button keeps working in the child row because it only needs the id to be unique and reachable from <body>. This matches how the suspend hold modal is already handled on the same page. To test: 1. Enable OPACAllowUserToChangeBranch (e.g. "pending,intransit,suspended") 2. Place a hold for a patron whose hold can be changed to another pickup library 3. Log in to the OPAC as that patron at a narrow viewport (e.g. browser devtools device emulation, 375px wide), and open the Holds tab 4. Expand the hold row with the "+" control and press "Change" next to the pickup location 5. Without the patch: the page greys out and no dialog is visible 6. Apply the patch and reload; repeat 7. Confirm the dialog is visible, pick another library, press Save and confirm the pickup location changes 8. Repeat at desktop width and confirm the modal still works there 9. Confirm the page contains no duplicate ids: in the console run document.querySelectorAll('[id="changePickup1"]').length and expect 1 Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com> Signed-off-by: David Nind <david@davidnind.com> -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=43991 Lisette Scheer <lisette@bywatersolutions.com> changed: What |Removed |Added ---------------------------------------------------------------------------- QA Contact|testopia@bugs.koha-communit |Laura.escamilla@bywatersolu |y.org |tions.com -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=43991 Laura Escamilla <Laura.escamilla@bywatersolutions.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|Signed Off |Passed QA -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=43991 Laura Escamilla <Laura.escamilla@bywatersolutions.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Attachment #210561|0 |1 is obsolete| | -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=43991 --- Comment #3 from Laura Escamilla <Laura.escamilla@bywatersolutions.com> --- Created attachment 212430 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=212430&action=edit Bug 43991: Pickup location change modal is unusable on narrow OPAC screens On the OPAC summary page, the "Change" pickup location modal for each hold is rendered inside the "Pickup location" table cell of the holds table. On narrow viewports DataTables Responsive hides that column (td.dtr-hidden, display:none) and copies its markup into the expanded child row. This leaves two elements with the same id: the real modal in the hidden cell, and a dead copy in the child row. Bootstrap resolves data-bs-target="#changePickupN" to the first match, the one inside the hidden cell. The backdrop (appended to <body>) is shown, but the dialog has no layout box, so the patron sees a greyed out page with no way to pick a library or dismiss the modal. Render the modals after the table instead, in their own loop. The "Change" button keeps working in the child row because it only needs the id to be unique and reachable from <body>. This matches how the suspend hold modal is already handled on the same page. To test: 1. Enable OPACAllowUserToChangeBranch (e.g. "pending,intransit,suspended") 2. Place a hold for a patron whose hold can be changed to another pickup library 3. Log in to the OPAC as that patron at a narrow viewport (e.g. browser devtools device emulation, 375px wide), and open the Holds tab 4. Expand the hold row with the "+" control and press "Change" next to the pickup location 5. Without the patch: the page greys out and no dialog is visible 6. Apply the patch and reload; repeat 7. Confirm the dialog is visible, pick another library, press Save and confirm the pickup location changes 8. Repeat at desktop width and confirm the modal still works there 9. Confirm the page contains no duplicate ids: in the console run document.querySelectorAll('[id="changePickup1"]').length and expect 1 Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com> Signed-off-by: David Nind <david@davidnind.com> Signed-off-by: Laura_Escamilla <laura.escamilla@bywatersolutions.com> -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=43991 Laura Escamilla <Laura.escamilla@bywatersolutions.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Text to go in the| |Fixed an issue where release notes| |patrons could not see the | |change pickup location | |dialog for holds on mobile | |devices. The dialog now | |displays correctly on | |smaller screens, allowing | |patrons to change their | |hold pickup location. -- You are receiving this mail because: You are watching all bug changes.
participants (1)
-
bugzilla-daemon@bugs.koha-community.org