mirror of
https://github.com/Sea-Haven-Industries/shoc-frontend-new.git
synced 2026-10-01 20:13:12 +00:00
test(dashboard): give the visual fixture an Unassigned count (SH-392)
This commit is contained in:
parent
ed931ea2eb
commit
fca87b67cb
1 changed files with 5 additions and 1 deletions
|
|
@ -191,7 +191,11 @@ async function mockDashboardApi(page: Page, userRoles: string) {
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
if (pathname.includes("/Dashboard/Stats")) return fulfillJson(route, { data: STATS });
|
if (pathname.includes("/Dashboard/Stats")) {
|
||||||
|
// The server reports no unassigned work for a dispatcher-scoped view (SH-392).
|
||||||
|
const unassigned = userRoles === "Dispatcher" ? 0 : 11;
|
||||||
|
return fulfillJson(route, { data: { ...STATS, unassigned } });
|
||||||
|
}
|
||||||
if (pathname.includes("/Dashboard/Workload")) return fulfillJson(route, { data: WORKLOAD });
|
if (pathname.includes("/Dashboard/Workload")) return fulfillJson(route, { data: WORKLOAD });
|
||||||
if (pathname.includes("/Dashboard/Performance"))
|
if (pathname.includes("/Dashboard/Performance"))
|
||||||
return fulfillJson(route, { data: PERFORMANCE });
|
return fulfillJson(route, { data: PERFORMANCE });
|
||||||
|
|
|
||||||
Loading…
Add table
Reference in a new issue