Receive Clear Feedback When Access Is Denied to a Route
When an authenticated user navigates to a route that requires permissions their current role does not grant, the Permission Guard redirects them to the No-Access Screen. This screen clearly explains the reason for denied access and presents actionable options such as switching to a different role (if eligible) or contacting support. This prevents confusing blank states and reduces support burden by giving users self-service resolution paths. Global admins who attempt standard app flows are redirected here with guidance toward the admin portal.
User Story
Acceptance Criteria
- Given a user with an insufficient role attempts to access a restricted route, when the Permission Guard evaluates the request, then the user is redirected to the No-Access Screen
- Given the No-Access Screen is displayed, when the user views it, then it shows a clear human-readable explanation of why access was denied
- Given the user has multiple roles and is on the No-Access Screen, when they view the screen, then a role switch option is visible and functional
- Given the user has only one role and is on the No-Access Screen, when they view the screen, then a contact support option is presented
- Given a Global Administrator attempts to access standard app routes, when the Permission Guard evaluates the request, then they are redirected to the No-Access Screen with guidance toward the admin portal
- Given the No-Access Screen is displayed, when the user presses the back button, then they are navigated to a safe fallback screen without error
Business Value
Silent failures and blank screens when access is denied are a major source of support requests and user confusion. A clear no-access screen with self-service options reduces coordinator and support team burden significantly. For global admins who should never use standard app flows, this screen provides critical guidance preventing them from accidentally modifying production data in the wrong context.
Components
- No-Access Screen ui
- Permission Guard service
- Role Authorization Service service