Skip to content

Fix Grant All checkbox not showing indeterminate state in permission modal#24807

Open
maliming wants to merge 2 commits intorel-10.0from
fix/permission-modal-grant-all-indeterminate-state
Open

Fix Grant All checkbox not showing indeterminate state in permission modal#24807
maliming wants to merge 2 commits intorel-10.0from
fix/permission-modal-grant-all-indeterminate-state

Conversation

@maliming
Copy link
Member

@maliming maliming commented Feb 5, 2026

Summary

  • Fixed the "Grant All Permissions" checkbox not displaying indeterminate state when only some permission groups are fully selected
  • Changed GrantAll and GrantAny calculation to use _allGroups instead of _groups (filtered list)
  • Affected methods: GroupGrantAllChanged, PermissionChanged, and OnPermissionGroupSearchTextChangedAsync

Problem

When selecting "Select All" for a specific permission group in the Blazor permission modal, the top-level "Grant All Permissions" checkbox appeared as if all permissions were granted, instead of showing the indeterminate ("-") state.

Root Cause

The GrantAll and GrantAny properties were calculated based on _groups (the filtered/visible list) instead of _allGroups (all permission groups). This caused incorrect state when:

  • Groups were filtered via search
  • Only some groups had all permissions selected

Test plan

  • Open permission management modal with multiple permission groups
  • Click "Select All in This Tab" for one group only
  • Verify the top "Grant All Permissions" checkbox shows indeterminate state (-)
  • Filter groups using search, then select all in a filtered group
  • Verify the top checkbox still shows correct indeterminate state

🤖 Generated with Claude Code

…modal

When selecting "Select All" for a specific permission group, the "Grant All Permissions"
checkbox should display an indeterminate state if not all permissions are granted.

The issue was that GrantAll and GrantAny were calculated based on _groups (filtered list)
instead of _allGroups (all groups), causing incorrect checkbox state when groups were filtered.

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
Copilot AI review requested due to automatic review settings February 5, 2026 06:17
@maliming maliming requested a review from yagmurcelk February 5, 2026 06:18
@maliming maliming added this to the 10.0-patch-final milestone Feb 5, 2026
Copy link
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This PR fixes a bug in the Blazor permission management modal where the "Grant All Permissions" checkbox did not correctly display an indeterminate state when only some permission groups had all their permissions selected.

Changes:

  • Changed GrantAll and GrantAny property calculations to use _allGroups (all permission groups) instead of _groups (filtered/visible groups) in three methods
  • Fixed the checkbox state calculation to reflect the actual state of all permissions, not just the filtered/visible ones

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant