package dao import "server/global" // Booth 岗亭模型 type Booth struct { global.GVA_MODEL BoothCode string `gorm:"size:50;not null;uniqueIndex" json:"booth_code"` // 岗亭编码 BoothName string `gorm:"size:100;not null" json:"booth_name"` // 岗亭名称 IPAddress string `gorm:"size:50" json:"ip_address"` // IP地址 Description string `gorm:"size:200" json:"description"` // 备注 ParkingLotID uint `gorm:"index;comment:所属区域ID" json:"parking_lot_id"` // 所属区域ID ParkingLot *ParkingLot `gorm:"foreignkey:parking_lot_id" json:"parking_lot"` Channels []Channel `gorm:"foreignKey:BoothID" json:"channels"` } func (Booth) TableName() string { return "booth" }