shivaansh0610-LUFFY opened a new pull request, #602: URL: https://github.com/apache/fineract-backoffice-ui/pull/602
Fixes #577 ## Problem `/clients/view/:id` for a missing or unauthorized client rendered a blank content area after a toast that auto-dismissed while echoing the backend's raw error payload (`[id] Client not found with valuer 99999`). ## Fix - `ClientViewComponent.loadClientData()` now classifies the failure into a `loadError` signal: a 404/403 renders **"This client doesn't exist, or you don't have permission to view it."** with a **Back to clients** action; any other failure (500, network) renders a generic message with **Try again**, which retries the same request. - The request opts out of the global error toast via the existing `skipErrorToast()` HTTP context, since the screen now reports the failure itself — no more raw `defaultUserMessage`/parameter-name text reaching the user. - The rendering lives in a new shared `app-load-error` component (`src/app/shared/components/load-error/`) rather than inline markup, so #223's list-view fix can reuse it without a second implementation. `GroupViewComponent`/`CenterViewComponent` already carry an inline version of this pattern; this PR does not touch them, to keep the change focused on the client detail route per the issue. ## Screenshots **Not-found / no-permission state (404):**  **Load-failed state with retry (500):**  ## Video A short recording of both flows (not-found → Back to clients, and load-failed → Try again → recovers) is attached below. ## Test plan - [x] `npm run lint` - [x] `npm run format:check` - [x] `npm run test:unit` (new unit tests for `ClientViewComponent`'s 404/403/500 paths and for `LoadErrorComponent`) - [x] `npm run i18n:check`, `npm run check:icons`, `npm run check:a11y-names` - [x] `npm run build` - [x] `./scripts/check-license.sh` - [x] New mocked Playwright spec: `npx playwright test --project=mocked e2e/client-load-error.spec.ts` (also re-ran `client.spec.ts`, `client-empty-account-cta.spec.ts`, `client-legal-form-search.spec.ts`, `client-date-picker-revisit.spec.ts` for regressions) Manual verification: sign in, navigate to `/clients/view/99999` (or any nonexistent id) — no toast, persistent message with a working Back to clients button. 🤖 Generated with [Claude Code](https://claude.com/claude-code) -- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. To unsubscribe, e-mail: [email protected] For queries about this service, please contact Infrastructure at: [email protected]
