feat: refine admin forms, attendance and finance workflows
Squash merge PR #23. Included changes: - complete occupancy check-in required fields/default payload - improve responsive admin management pages - fix attendance edge cases and attendance period config - refine wallet/finance-related workflow handling Checks: - npm run typecheck -w apps/admin - npm run typecheck -w apps/server
This commit is contained in:
@@ -25,7 +25,9 @@ type Role = keyof typeof CREDENTIALS;
|
||||
* Login as a specific role and store the token in localStorage.
|
||||
* Returns the parsed response data.
|
||||
*/
|
||||
export async function loginAs(role: Role): Promise<{ token: string; user: Record<string, unknown> }> {
|
||||
export async function loginAs(
|
||||
role: Role,
|
||||
): Promise<{ token: string; user: Record<string, unknown> }> {
|
||||
const creds = CREDENTIALS[role];
|
||||
const res = await fetch(`${BASE}/api/auth/login`, {
|
||||
method: 'POST',
|
||||
|
||||
Reference in New Issue
Block a user