feat: customer-facing appointment notes (GRO-106) #109

Merged
groombook-engineer[bot] merged 7 commits from feat/gro-106-customer-notes into main 2026-03-26 08:24:21 +00:00
3 changed files with 7 additions and 9 deletions
Showing only changes of commit 1c1d0dac7b - Show all commits
-8
View File
@@ -24,14 +24,6 @@ const EXPIRED_SESSION = {
createdAt: new Date(),
};
const ENDED_SESSION = {
id: SESSION_ID,
clientId: CLIENT_ID,
status: "ended" as const,
expiresAt: futureDate(),
createdAt: new Date(),
};
const APPOINTMENT = {
id: APPOINTMENT_ID,
clientId: CLIENT_ID,
+3 -1
View File
@@ -57,6 +57,9 @@ app.get("/api/branding", async (c) => {
});
});
// Portal routes — no staff auth required, uses impersonation session for client auth
app.route("/api/portal", portalRouter);
// Protected API routes
const api = app.basePath("/api");
api.use("*", authMiddleware);
@@ -108,7 +111,6 @@ api.route("/clients", clientsRouter);
api.route("/pets", petsRouter);
api.route("/services", servicesRouter);
api.route("/appointments", appointmentsRouter);
api.route("/portal", portalRouter);
api.route("/staff", staffRouter);
api.route("/invoices", invoicesRouter);
api.route("/reports", reportsRouter);
+4
View File
@@ -64,6 +64,10 @@ portalRouter.patch(
.where(eq(appointments.id, id))
.returning();
if (!updated) {
return c.json({ error: "Not found" }, 404);
}
return c.json({
id: updated.id,
customerNotes: updated.customerNotes,