feat(GRO-1174): persist petSizeCategory and petCoatType from booking

- Add petSizeCategory and petCoatType to bookingSchema zod validator (optional)
- Save coatType to pets row on booking creation
- Add coatType and petSizeCategory columns to pets DB schema
- Add coatType and petSizeCategory to Pet interface in @groombook/types

Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
This commit is contained in:
2026-05-20 04:40:42 +00:00
committed by Flea Flicker [agent]
parent 539ef21d89
commit faf7def77d
3 changed files with 7 additions and 0 deletions
+3
View File
@@ -112,6 +112,8 @@ const bookingSchema = z.object({
petName: z.string().min(1).max(200),
petSpecies: z.string().min(1).max(100),
petBreed: z.string().max(100).optional(),
petSizeCategory: z.string().max(50).optional(),
petCoatType: z.string().max(50).optional(),
notes: z.string().max(2000).optional(),
});
@@ -191,6 +193,7 @@ bookRouter.post(
name: body.petName,
species: body.petSpecies,
breed: body.petBreed ?? null,
coatType: body.petCoatType ?? null,
})
.returning();
const pet = petInserted[0];