cooler_box.go 906 B

12345678910111213141516171819202122232425262728
  1. package model
  2. import model2 "cold-logistics/common/model"
  3. // 仓库
  4. type CoolerBox struct {
  5. model2.Model
  6. Name string `json:"name" gorm:"size:128"` // 保温箱名称
  7. Sn string `json:"sn" gorm:"size:128"` // sn
  8. Status string `json:"status" gorm:"size:4;not null;default:'2';comment:状态"` // 1-停用 2-启用
  9. HistorySn model2.StringList `json:"historySn"` // 历史绑定的sn
  10. model2.ControlBy
  11. model2.ModelTime
  12. model2.DeptBy
  13. }
  14. type CoolerBoxOmit struct {
  15. Id int `json:"id,omitempty"` // 主键编码
  16. Name string `json:"name,omitempty"` // 保温箱名称
  17. Sn string `json:"sn,omitempty"` // sn
  18. }
  19. func (CoolerBox) TableName() string {
  20. return "cooler_box"
  21. }
  22. func (CoolerBoxOmit) TableName() string {
  23. return "cooler_box"
  24. }