| | |
| | | ProductQuantity int64 `json:"productQuantity" gorm:"not null;default:0;comment:产品数量"` //产品数量 |
| | | SignTime string `gorm:"type:varchar(191);comment:签单时间" json:"signTime"` |
| | | DeliveryDate string `gorm:"type:varchar(191);comment:交货日期" json:"deliveryDate"` |
| | | EnterpriseID uint `gorm:"type:int;not null;default:0;comment:供应商ID" json:"enterpriseID"` //供应商ID |
| | | EnterpriseID uint `gorm:"type:int;not null;default:0;comment:供应商ID" json:"enterpriseID"` //供应商ID |
| | | EnterpriseName string `json:"enterpriseName" gorm:"type:varchar(255);not null;default:'';comment:供应商名称"` //供应商名称 |
| | | EnterpriseType string `json:"enterpriseType" gorm:"type:varchar(255);not null;default:'';comment:供应商类型"` //供应商类型 |
| | | Status constvar.OutsourcingOrderStatus `json:"status" gorm:"type:tinyint(1);not null;default:0;comment:状态"` //状态 |
| | | Status constvar.OutsourcingOrderStatus `json:"status" gorm:"type:tinyint(1);not null;default:0;comment:状态"` //状态 |
| | | Reason string `json:"reason" gorm:"type:varchar(255);comment:不通过理由"` |
| | | } |
| | | |
| | |
| | | db = db.Order(slf.Order) |
| | | } |
| | | |
| | | if slf.Keyword != "" { |
| | | db = db.Where("enterprise_name like ?", fmt.Sprintf("%%%s%%", slf.Keyword)) |
| | | } |
| | | if slf.Keyword != "" { |
| | | keywordFmt := fmt.Sprintf("%%%s%%", slf.Keyword) |
| | | db = db.Where("number like ? or enterprise_name like ? or enterprise_type like ?", keywordFmt, keywordFmt, keywordFmt) |