Skip to content

Bug: hideBulkActions won't work on pages with custom list view where table-actions is set to true on ResourceTable #17426

@aalves08

Description

@aalves08

Setup

  • Rancher version: v2.14 / master (v2.15 development)
  • Rancher UI Extensions: Product Registration API (experimental)
  • Browser type & version: N/A (code-level issue)

Describe the bug

The DSL hideBulkActions method correctly sets state.hideBulkActions[type] = true in the type-map store, and the ResourceTable component's _showBulkActions computed correctly checks this via type-map/hideBulkActionsFor. However, some resource types have custom list components (under shell/list/) that render their own <ResourceTable> with a hardcoded :table-actions="true" prop. This prop takes precedence over the store-based check, making the hideBulkActions DSL method ineffective for those resource types.

To Reproduce

  1. In an extension, register a resource page for provisioning.cattle.io.cluster with hideBulkActions: true (either via the new product registration API or the legacy DSL)
  2. Navigate to the resource list page
  3. Observe that bulk action checkboxes are still visible

Result

Bulk action checkboxes are still shown in the table despite hideBulkActions being set to true in the store.

The _showBulkActions computed in ResourceTable.vue exits early at the tableActions !== null check because the custom list component at shell/list/provisioning.cattle.io.cluster.vue (line 241) passes :table-actions="true" directly. This means the store-based hideBulkActionsFor getter is never consulted.

Expected Result

When hideBulkActions(type, true) is called via the DSL, bulk action checkboxes should be hidden for that resource type, regardless of whether the resource type has a custom list component.

Screenshots
N/A

Additional context

The affected file is shell/list/provisioning.cattle.io.cluster.vue, but this pattern likely exists in other custom list components as well. A quick search shows multiple custom list components using hardcoded :table-actions values.

Possible fixes:

  • Option A: In custom list components that hardcode :table-actions="true", replace it with a computed that also checks type-map/hideBulkActionsFor — respecting the DSL override while preserving the default behavior
  • Option B: In ResourceTable.vue, change _showBulkActions so that the store-based hideBulkActionsFor check takes precedence over the tableActions prop when the store explicitly sets it to hidden
  • Option C: Document that hideBulkActions only works for resource types that do NOT have a custom list component in shell/list/

Metadata

Metadata

Assignees

Type

No type
No fields configured for issues without a type.

Projects

No projects

Relationships

None yet

Development

No branches or pull requests

Issue actions