feat(portal): replace mock data with real session-driven API calls #152

Merged
groombook-engineer[bot] merged 25 commits from feat/gro-203-rbac-super-user into main 2026-03-29 07:08:35 +00:00
Showing only changes of commit 21df02eef8 - Show all commits
+2 -2
View File
@@ -1,7 +1,7 @@
import { Hono } from "hono";
import { zValidator } from "@hono/zod-validator";
import { z } from "zod/v3";
import { eq, exists, getDb, staff, businessSettings } from "@groombook/db";
import { eq, getDb, staff, businessSettings } from "@groombook/db";
import type { AppEnv } from "../middleware/rbac.js";
export const setupRouter = new Hono<AppEnv>();
@@ -70,7 +70,7 @@ setupRouter.post("/", zValidator("json", setupSchema), async (c) => {
});
if ("error" in result) {
return c.json({ error: result.error }, result.code as 409);
return c.json({ error: result.error }, result.code as number);
}
return c.json({ ok: true, staff: result.staff }, 201);