| | |
| | | WorkOrderID string `gorm:"index;type:varchar(191);not null" json:"workOrderID"` |
| | | OrderID string `gorm:"index;type:varchar(191);not null" json:"orderID"` |
| | | ProcedureID string `gorm:"type:varchar(191)" json:"procedureId"` |
| | | ProductProcedureID string `gorm:"type:varchar(191);not null" json:"productProcedureID"` //产品工序id |
| | | ProductProcedureID string `gorm:"type:varchar(191);" json:"productProcedureID"` //产品工序id |
| | | DeviceID string `gorm:"type:varchar(191);not null" json:"deviceId"` |
| | | FinishedQuantity int64 `gorm:"type:int;not null" json:"finishedQuantity"` |
| | | Channel int32 `gorm:"type:int" json:"channel"` //通道 |
| | |
| | | return slf |
| | | } |
| | | |
| | | func (slf *ProductionProgressSearch) SetProductProcedureId(productProcedureId string) *ProductionProgressSearch { |
| | | slf.ProductProcedureID = productProcedureId |
| | | return slf |
| | | } |
| | | |
| | | func (slf *ProductionProgressSearch) SetId(id uint) *ProductionProgressSearch { |
| | | slf.ID = id |
| | | return slf |
| | |
| | | db = db.Where("finished_quantity < total_quantity") |
| | | } |
| | | |
| | | if slf.ProductProcedureID != "" { |
| | | db = db.Where("product_procedure_id = ?", slf.ProductProcedureID) |
| | | } |
| | | |
| | | return db |
| | | } |
| | | |