Skip to content

Frontend: Roles and Permissions table view #568

Done
openedx/frontend-app-admin-console
#285

Description

@rodmgwgu

Build the Roles and Permissions table in frontend-app-admin-console, replacing the current hardcoded roles/permissions matrix sourced from course/constants.ts / library/constants.ts with data from the catalog endpoint (GET /api/authz/v1/roles/?scope_types=…, ADR 0028).

Page title "Roles and Permissions Management" with page-level "Assign Role" and "Create Custom Role" header buttons, under a "Roles and Permissions" tab alongside the existing "Team Members" tab.

Columns (exact, per design): Role, Type of resource (a pill: Courses / Libraries), Members (count), Permissions (e.g. "14 Granted"), Last updated (timestamp or "-"), Actions. A custom role shows a "Custom Role" sub-label beneath its name; the Actions column shows an eye (view) icon for standard roles and a pencil (edit) icon for custom roles, plus a kebab overflow menu on every row. Header carets mark the sortable columns (Role, Type of resource, Members, Last updated). Controls above the table: a Search box, a single "Type of resource" filter, and a "Showing N roles of M" count with prev/next pagination arrows.

Acceptance

  • Table renders roles for the active resource type from the API; no hardcoded role/permission copy remaining in the client.
  • Custom roles carry the "Custom Role" sub-label and the pencil action; standard roles carry the eye action (driven by definition_kind).
  • Columns exactly as above, including the Permissions-granted count.
  • Loading, empty and error states handled; accessible table semantics (Paragon DataTable).

Design: https://www.figma.com/design/xnmQJq1cTRVqNrs31R8zDM/AuthZ---v2?node-id=40000174-2&p=f&t=AfaPxKGH7lD48V93-0

Metadata

Metadata

Labels

willow

Type

No type

Projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions