controllers/report_forms_controller.go | ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史 | |
response/report_forms_response.go | ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史 |
controllers/report_forms_controller.go
@@ -134,7 +134,7 @@ for _, detail := range details { operationIds = append(operationIds, detail.OperationID) } //获取操作记录 //获取已完成的操作记录 operations, err := models.NewOperationSearch().SetIds(operationIds).SetStatus(constvar.OperationStatus_Finish).FindNotTotal() if err != nil { util.ResponseFormat(c, code.RequestParamError, "查询操作记录失败") @@ -145,11 +145,12 @@ var resp response.InventoryHistory resp.Amount = detail.Amount resp.Unit = params.Unit resp.ProductName = params.ProductName for _, operation := range operations { if detail.OperationID == operation.Id { resp.Number = operation.Number resp.Date = operation.UpdateTime resp.BaseOperationType = operation.BaseOperationType resp.Status = "完成" resp.ContactedName = operation.ContacterName resp.FromLocation = operation.FromLocation.Name resp.ToLocation = operation.ToLocation.Name response/report_forms_response.go
@@ -2,7 +2,6 @@ import ( "github.com/shopspring/decimal" "wms/constvar" ) type InventoryForms struct { @@ -19,14 +18,15 @@ } type InventoryHistory struct { Number string `json:"number"` //单号 Date string `json:"date"` //日期 FromLocation string `json:"fromLocation"` //源位置 ToLocation string `json:"toLocation"` //目标位置 Amount decimal.Decimal `json:"amount"` //数量 Unit string `json:"unit"` //单位 ContactedName string `json:"contactedName"` //完成者 BaseOperationType constvar.BaseOperationType `json:"baseOperationType"` //基础作业类型 Number string `json:"number"` //单号 Date string `json:"date"` //日期 ProductName string `json:"productName"` //产品名称 FromLocation string `json:"fromLocation"` //源位置 ToLocation string `json:"toLocation"` //目标位置 Amount decimal.Decimal `json:"amount"` //数量 Unit string `json:"unit"` //单位 ContactedName string `json:"contactedName"` //完成者 Status string `json:"status"` //状态 } type LocationForms struct {