fix(db): seed staff_id FK fix (GRO-369)

Fixes staff_id FK violation on re-seed: move TRUNCATE before staff upsert and add id to onConflictDoUpdate set clause.

Co-Authored-By: Paperclip <noreply@paperclip.ing>
This commit was merged in pull request #199.
This commit is contained in:
groombook-engineer[bot]
2026-04-01 14:19:49 +00:00
committed by GitHub
parent 07263a89fe
commit dff11d02be
6 changed files with 2102 additions and 26 deletions
+1 -1
View File
@@ -141,7 +141,7 @@ export const pets = pgTable("pets", {
export const services = pgTable("services", {
id: uuid("id").primaryKey().defaultRandom(),
name: text("name").notNull(),
name: text("name").notNull().unique(),
description: text("description"),
basePriceCents: integer("base_price_cents").notNull(),
durationMinutes: integer("duration_minutes").notNull(),