Skip to content

← Back to list feature

Dynamic Module-Based Navigation

The FE sidebar is built from the BE response so the menu always reflects the current user's role and module access.

The FE sidebar is built from the BE response that lists modules the user is allowed to access.

Problem

Hardcoded menu list does not reflect actual per-role module access.

Decision

Backend returns only the modules the user is allowed to access; FE renders what is sent.

Result

Modules without access never reach the FE; no hardcoded menu list.

Implementation

  • The FE sidebar is entirely composed from the BE response; no hardcoded menu.
  • Modules without permission are omitted by the backend (never sent to FE).
  • No measurable performance impact despite filtering on the FE side.

Related screenshots

Sidebar rendered from the BE response based on the admin role_module rows.
master-items, user-management, and role-management modules are filtered out for staff.