feat(layout): Add Tiers to FacilitySection and Position
- 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:
parent
9cabd54718
commit
3a11590795
1 changed files with 3 additions and 1 deletions
|
|
@ -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")
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue