feat(layout): Add Tiers to FacilitySection and Position
Some checks failed
Deploy to Production / deploy (push) Failing after 0s
Test / backend-test (push) Failing after 0s
Test / frontend-test (push) Failing after 0s

- Added 'tiers' to FacilitySection for multi-level racks
- Added 'tier' to FacilityPosition for Z-axis addressing
- Updated unique constraint for positions
This commit is contained in:
fullsizemalt 2025-12-11 13:21:05 -08:00
parent 9cabd54718
commit 3a11590795

View file

@ -587,6 +587,7 @@ model FacilitySection {
height Int
rows Int // Grid rows
columns Int // Grid columns
tiers Int @default(1) // Number of vertical tiers
spacing Int @default(12) // inches between positions
positions FacilityPosition[]
createdAt DateTime @default(now())
@ -601,11 +602,12 @@ model FacilityPosition {
sectionId String
row Int
column Int
tier Int @default(1) // Vertical level (1 = bottom)
slot Int @default(1) // For multi-plant positions
status String @default("EMPTY") // EMPTY, OCCUPIED, RESERVED, DAMAGED
plant FacilityPlant?
@@unique([sectionId, row, column, slot])
@@unique([sectionId, row, column, tier, slot])
@@map("facility_positions")
}