Bug 37604 - Give skip_open_orders checkbox an ID in batch record deletion template
Summary: Give skip_open_orders checkbox an ID in batch record deletion template
Status: Pushed to main
Alias: None
Product: Koha
Classification: Unclassified
Component: Cataloging (show other bugs)
Version: Main
Hardware: All All
: P5 - low enhancement
Assignee: Aman
QA Contact: Marcel de Rooy
URL:
Keywords: Academy, accessibility
Depends on: 27893
Blocks:
  Show dependency treegraph
 
Reported: 2024-08-09 00:25 UTC by Aleisha Amohia
Modified: 2025-07-23 22:41 UTC (History)
4 users (show)

See Also:
GIT URL:
Change sponsored?: ---
Patch complexity: Trivial patch
Documentation contact:
Documentation submission:
Text to go in the release notes:
This enhancement adds an ID to the "Skip bibliographic records with open acquisition orders" checkbox on the batch record deletion page (Cataloging > Batch editing > Batch record deletion"). This is required so that when selecting or unselecting the checkbox, the focus remains on the checkbox. The ID semantically links the checkbox to its label so machines (screenreaders and computers) can tell they are related elements.
Version(s) released in:
25.11.00
Circulation function:


Attachments
Bug 37604 - Give skip_open_orders checkbox an ID in batch record deletion template (1.61 KB, patch)
2025-07-17 23:47 UTC, Aman
Details | Diff | Splinter Review
Bug 37604: Add an ID to the batch record deletion "Skip biblio...." checkbox (2.21 KB, patch)
2025-07-18 04:55 UTC, David Nind
Details | Diff | Splinter Review
Bug 37604: Add an ID to the batch record deletion "Skip biblio...." checkbox (2.30 KB, patch)
2025-07-18 06:11 UTC, Marcel de Rooy
Details | Diff | Splinter Review

Note You need to log in before you can comment on or make changes to this bug.
Description Aleisha Amohia 2024-08-09 00:25:15 UTC
This is so that clicking on the label will put the cursor focus on the checkbox. At the moment the label and the checkbox are not semantically 'linked' without an ID
Comment 1 Aman 2025-07-17 23:47:06 UTC
Created attachment 184260 [details] [review]
Bug 37604 - Give skip_open_orders checkbox an ID in batch record deletion template

To Test:
1. Navigate to Home > Cataloging > Batch record deletion
2. Click 'Skip bibliographic records with open acquisition orders' to toggle
the Record type checkbox
Comment 2 David Nind 2025-07-18 04:55:13 UTC
Created attachment 184275 [details] [review]
Bug 37604: Add an ID to the batch record deletion "Skip biblio...." checkbox

This patch adds an ID to the "Skip bibliographic records with open
acquisition orders" checkbox on the batch record deletion page (Cataloging >
Batch editing > Batch record deletion".

This is required so that when selecting or unselecting the checkbox, the focus
remains on the checkbox.

Test plan:
1. Navigate to Home > Cataloging > Batch record deletion
2. Click 'Skip bibliographic records with open acquisition orders' to toggle
   the Record type checkbox (selected by default).
3. Inspect the page (right click the page, select Inspect, and look at the
   values in the checheckbox input field):
  . before the patch there is no id for the field
  . after the patch there is an id="skip_open_orders" for the checkbox field

Signed-off-by: David Nind <david@davidnind.com>
Comment 3 David Nind 2025-07-18 05:01:31 UTC
Thanks for the patch Aman!

I've signed off the patch, as it does add an ID to the checkbox.

However, I don't exactly understand what is changed or why (I didn't notice any change in behavour) - probably reflecting my lack of accessibility related knowledge!

I also updated the commit message (see the commit message guidelines https://wiki.koha-community.org/wiki/Commit_messages). I changed the format of the title and added a description - it should describe what problem the patch solves.

I've also added a draft release note. This should be updated to reflect what the problem is that it solves.

David Nind
Comment 4 Marcel de Rooy 2025-07-18 06:11:39 UTC
Created attachment 184276 [details] [review]
Bug 37604: Add an ID to the batch record deletion "Skip biblio...." checkbox

This patch adds an ID to the "Skip bibliographic records with open
acquisition orders" checkbox on the batch record deletion page (Cataloging >
Batch editing > Batch record deletion".

This is required so that when selecting or unselecting the checkbox, the focus
remains on the checkbox.

Test plan:
1. Navigate to Home > Cataloging > Batch record deletion
2. Click 'Skip bibliographic records with open acquisition orders' to toggle
   the Record type checkbox (selected by default).
3. Inspect the page (right click the page, select Inspect, and look at the
   values in the checheckbox input field):
  . before the patch there is no id for the field
  . after the patch there is an id="skip_open_orders" for the checkbox field

Signed-off-by: David Nind <david@davidnind.com>

Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl>
Comment 5 Aleisha Amohia 2025-07-20 21:30:08 UTC
(In reply to David Nind from comment #3)
> However, I don't exactly understand what is changed or why (I didn't notice
> any change in behavour) - probably reflecting my lack of accessibility
> related knowledge!
> 

Thanks David - I half explained it in the description but could be more clear!

Adding an ID to semantically link the label to the checkbox is important for those using screen readers or keyboard navigation to interact reliably with the form.

Many users will be able to look at the label and checkbox and see that they are laid out next to each other and assume they are related. However, adding the input "id" to match the label "for" tells machines that they are related.

Hope that makes sense!
Comment 6 Lucas Gass (lukeg) 2025-07-23 22:39:53 UTC
Nice work everyone!

Pushed to main for 25.11