From 2674bcb2b6f9279d748846f207b580eaed5e1c41 Mon Sep 17 00:00:00 2001 From: "groombook-engineer[bot]" <3141748+groombook-engineer[bot]@users.noreply.github.com> Date: Wed, 1 Apr 2026 20:18:31 +0000 Subject: [PATCH 1/3] fix(db): add impersonation_sessions and audit_logs to seed TRUNCATE chain Truncate these tables before staff upsert to avoid FK constraint violations when the dev DB already has impersonation sessions referencing staff rows. Co-Authored-By: Paperclip --- packages/db/src/seed.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/packages/db/src/seed.ts b/packages/db/src/seed.ts index 8b1a6c1..19d8fda 100644 --- a/packages/db/src/seed.ts +++ b/packages/db/src/seed.ts @@ -428,7 +428,7 @@ async function seed() { // Truncate downstream tables before services upsert — clears stale appointments // from prior seed runs so the FK constraint on service_id is never violated - await db.execute(sql`TRUNCATE appointments, invoices, invoice_line_items, invoice_tip_splits, grooming_visit_logs CASCADE`); + await db.execute(sql`TRUNCATE impersonation_sessions, impersonation_audit_logs, appointments, invoices, invoice_line_items, invoice_tip_splits, grooming_visit_logs CASCADE`); // ── Services ── // Upsert services using name as unique key. With deterministic IDs in -- 2.52.0 From 88170091b7500531b32157f227da51541f95fdec Mon Sep 17 00:00:00 2001 From: "groombook-engineer[bot]" <3141748+groombook-engineer[bot]@users.noreply.github.com> Date: Wed, 1 Apr 2026 23:08:30 +0000 Subject: [PATCH 2/3] fix: enable Go to Dashboard button on setup wizard final step The "Go to Dashboard" button on Step 5 of the setup wizard was permanently disabled because the disabled attribute checked !canGoNext, which is always true on the last step (since canGoNext only allows advancing to the next step). Changed the disabled attribute from: disabled={!canGoNext || loading} to: disabled={(!canGoNext && !isLast) || loading} This allows the button to be clickable on the final step while preserving validation on steps 1-4. The navigate("/admin") call already handles the last-step click correctly. Fixes GRO-373. Co-Authored-By: Paperclip --- apps/web/src/pages/SetupWizard.jsx | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/apps/web/src/pages/SetupWizard.jsx b/apps/web/src/pages/SetupWizard.jsx index 69ed08d..6620845 100644 --- a/apps/web/src/pages/SetupWizard.jsx +++ b/apps/web/src/pages/SetupWizard.jsx @@ -204,7 +204,7 @@ export function SetupWizard() { )}