Use JS Prefixed Class for Row Checkboxes in VBO.

Created on 7 November 2023, about 1 year ago
Updated 17 January 2024, 11 months ago

Problem/Motivation

Currently, the .form-checkbox class is used as a selector for checkboxes within the Views Bulk Operations (VBO) module. This assumption may not hold true in all scenarios and can lead to issues when customizing checkboxes in a view. For example, if you modify the checkbox template and remove the form-checkbox class, VBO may no longer recognize these checkboxes as selectable items. Another example is if there is another checkbox added into the view this will cause problems to the selector.

Steps to reproduce

  1. Create a view with VBO enabled.
  2. Implement a form alteration on the view, adding custom checkboxes to it.
  3. Check one of the custom checkboxes.
  4. Notice that VBO includes it as one of its selectors.
  5. Modify the your theme checkbox template and remove the .form-checkbox class.
  6. Attempt to apply actions to selected items using the checkboxes.

Proposed resolution

To improve the VBO module, propose using a JavaScript (JS) prefixed class as a selector for row checkboxes. This change will make the module more robust and adaptable to various checkbox customizations.

πŸ› Bug report
Status

Fixed

Version

4.2

Component

Core

Created by

πŸ‡¨πŸ‡¦Canada justint

Live updates comments and jobs are added and updated live.
Sign in to follow issues

Comments & Activities

Not all content is available!

It's likely this issue predates Contrib.social: some issue and comment data are missing.

Production build 0.71.5 2024