zhangqian
2023-10-09 81cda4f09d4c0fff6edd087d1c49d05cb6eaab38
model/procedures.go
@@ -12,18 +12,19 @@
type (
   Procedures struct {
      gorm.Model     `json:"-"`
      ID             int    `gorm:"primarykey"`
      WorkOrderID    string `gorm:"index;type:varchar(191);not null;comment:工单ID" json:"-"`
      OrderID        string `gorm:"index;type:varchar(191);not null;comment:订单ID" json:"-"`
      DeviceID       string `gorm:"index;type:varchar(191);comment:设备ID" json:"deviceId"`
      ProcedureID    string `gorm:"index;type:varchar(191);comment:工序ID" json:"procedureId"`
      Channel        int32  `gorm:"index;comment:通道" json:"channel"` //通道
      StartTime      int64  `gorm:"comment:计划开始时间" json:"startTime"`
      EndTime        int64  `gorm:"comment:计划结束时间" json:"endTime"`
      Status         ProcedureStatus
      ProcedureData  string                  `json:"-"`                  //common.ProductProcedure  json串
      ProceduresInfo common.ProductProcedure `json:"procedure" gorm:"-"` //common.ProductProcedure  对象
      gorm.Model         `json:"-"`
      ID                 int    `gorm:"primarykey"`
      WorkOrderID        string `gorm:"index;type:varchar(191);not null;comment:工单ID" json:"-"`
      OrderID            string `gorm:"index;type:varchar(191);not null;comment:订单ID" json:"-"`
      DeviceID           string `gorm:"index;type:varchar(191);comment:设备ID" json:"deviceId"`
      ProcedureID        string `gorm:"index;type:varchar(191);comment:工序ID" json:"procedureId"`
      Channel            int32  `gorm:"index;comment:通道" json:"channel"`                //通道
      ProcessModelNumber string `gorm:"index;comment:工艺模型编号" json:"processModelNumber"` //工艺模型编号
      StartTime          int64  `gorm:"comment:计划开始时间" json:"startTime"`
      EndTime            int64  `gorm:"comment:计划结束时间" json:"endTime"`
      Status             ProcedureStatus
      ProcedureData      string                  `json:"-"`                  //common.ProductProcedure  json串
      ProceduresInfo     common.ProductProcedure `json:"procedure" gorm:"-"` //common.ProductProcedure  对象
   }
   ProceduresSearch struct {
@@ -137,11 +138,6 @@
func (slf *ProceduresSearch) SetChannels(channels []int32) *ProceduresSearch {
   slf.Channels = channels
   return slf
}
func (slf *ProceduresSearch) SetChannel(channel int32) *ProceduresSearch {
   slf.Channel = channel
   return slf
}