Bug 40783

Summary: The bookbag_form should not be submittable
Product: Koha Reporter: Jake Deery <jake.deery>
Component: OPACAssignee: Jake Deery <jake.deery>
Status: Needs Signoff --- QA Contact: Testopia <testopia>
Severity: trivial    
Priority: P5 - low CC: jake.deery
Version: Main   
Hardware: All   
OS: All   
GIT URL: Change sponsored?: ---
Patch complexity: --- Documentation contact:
Documentation submission: Text to go in the release notes:
Version(s) released in:
Circulation function:
Attachments: Bug 40783: Fix erroneous bookbag_form submission

Description Jake Deery 2025-09-10 09:12:17 UTC
The bookbag_form on the OPAC search results page should not submit by default. This causes accessibility problems, as it appears as though a page refresh occurs needlessly.
Comment 1 Jake Deery 2025-09-10 09:13:58 UTC
Created attachment 186311 [details] [review]
Bug 40783: Fix erroneous bookbag_form submission

This patch addresses a bug where pressing return when focused on the
bookbag_form checkbox results in a form submission. The bookbag_form is
not designed to be submitted, so the behaviour has been disabled for
accessibility reasons.

TO TEST:
a)  go to /cgi-bin/koha/opac-search.pl?idx=kw&q=history&sort_by=relevance
b)  add an item to your cart (ensure the syspref is enabled)
c)  tab through the results until you come across a checkbox, press
return
d)  notice your page refresh, a form submission has happened
APPLY PATCH
e)  repeat steps a-c
f)  notice the page no longer refreshes, and that no form submission
occurs
g)  notice the items are still in your cart and can be interacted with
normally
SIGN OFF