parking_lot.go 1.9 KB

123456789101112131415161718192021222324252627282930313233
  1. package request
  2. // ParkingLotCreate 停车区域创建请求
  3. type ParkingLotCreate struct {
  4. LotCode string `json:"lot_code"` // 区域编码
  5. LotName string `json:"lot_name"` // 区域名称
  6. Capacity int `json:"capacity" binding:"min=0"` // 车位数量
  7. AllowTemporaryWhenFull bool `json:"allow_temporary_when_full"` // 满位时允许临时车入场
  8. AllowMonthlyWhenFull bool `json:"allow_monthly_when_full"` // 满位时允许有效月租车入场
  9. AllowVIPWhenFull bool `json:"allow_vip_when_full"` // 满位时允许有效 VIP 车入场
  10. Description string `json:"description"` // 备注
  11. }
  12. // ParkingLotUpdate 停车区域更新请求
  13. type ParkingLotUpdate struct {
  14. ID uint `json:"id"` // 区域ID
  15. LotCode string `json:"lot_code"` // 区域编码
  16. LotName string `json:"lot_name"` // 区域名称
  17. Capacity int `json:"capacity" binding:"min=0"` // 车位数量
  18. AllowTemporaryWhenFull bool `json:"allow_temporary_when_full"` // 满位时允许临时车入场
  19. AllowMonthlyWhenFull bool `json:"allow_monthly_when_full"` // 满位时允许有效月租车入场
  20. AllowVIPWhenFull bool `json:"allow_vip_when_full"` // 满位时允许有效 VIP 车入场
  21. Description string `json:"description"` // 备注
  22. }
  23. // ParkingLotQuery 停车区域查询请求
  24. type ParkingLotQuery struct {
  25. LotCode string `form:"lot_code"` // 区域编码
  26. LotName string `form:"lot_name"` // 区域名称
  27. LotId int `form:"lot_id"` // 区域id
  28. Page int `form:"page,default=1"` // 页码
  29. PageSize int `form:"page_size,default=10"` // 每页数量
  30. }