Skip to content
This repository was archived by the owner on Nov 4, 2026. It is now read-only.
This repository was archived by the owner on Nov 4, 2026. It is now read-only.

Access pillar '已分配用户' counts only DIRECT grants — holders via position bindings show as 0 人 #2382

Closed

Description

@os-zhuang

Dogfooding the Access pillar (permission matrix) as a business admin on a live showcase boot:

  1. Bind showcase_contributor to the contributor position (sys_position_permission_set, 201).
  2. Assign a user to contributor (sys_user_position, 201).
  3. Reload the pillar → the set's 已分配用户 footer still reads 0 人 /「还没有分配任何用户」.

The count evidently reads sys_user_permission_set (direct grants) only. In the ADR-0090 model positions are THE distribution channel — direct grants are the exception — so for any normally-administered set the footer permanently shows 0, and an admin auditing "who holds this?" is told nobody right before they edit or delete a set that a whole position's population depends on.

Suggested shape

Count (and list) effective holders = direct grants ∪ holders of every position bound to the set (sys_position_permission_set → sys_user_position), with a per-row via badge (直授 / via 岗位 X) — same attribution vocabulary the explain panel already uses. The blast-radius sentence in framework's access-matrix drift output ("~N users") wants the same resolution.

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

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions