From aeed976c2999e2cea097cdee38d8baeefe323f3d Mon Sep 17 00:00:00 2001 From: liujiandao <274878379@qq.com> Date: 星期六, 30 三月 2024 16:15:59 +0800 Subject: [PATCH] 修改 --- controllers/report_forms_controller.go | 5 +++-- 1 files changed, 3 insertions(+), 2 deletions(-) diff --git a/controllers/report_forms_controller.go b/controllers/report_forms_controller.go index b6c8866..ced1c45 100644 --- a/controllers/report_forms_controller.go +++ b/controllers/report_forms_controller.go @@ -97,8 +97,8 @@ Where("wms_operation.base_operation_type in (?)", []constvar.BaseOperationType{constvar.BaseOperationTypeOutgoing, constvar.BaseOperationTypeInternal, constvar.BaseOperationTypeDisuse}). Where("wms_operation.status in (?)", []constvar.OperationStatus{constvar.OperationStatus_Ready, constvar.OperationStatus_Finish}) if len(locationIds) > 0 { - dbIn.Where("wms_operation.to_location_id in (?)", locationIds) - dbOut.Where("wms_operation.from_location_id in (?)", locationIds) + dbIn.Where("wms_operation_details.to_location_id in (?)", locationIds) + dbOut.Where("wms_operation_details.from_location_id in (?)", locationIds) } if len(productIds) > 0 { dbIn.Where("wms_operation_details.product_id in (?)", productIds) @@ -339,6 +339,7 @@ for _, amount := range amounts { var resp response.LocationForms resp.Amount = amount.Amount + resp.LocationId = amount.LocationId resp.LocationName = amount.Location.Name resp.ProduceId = amount.Product.ID resp.ProductName = amount.Product.Name -- Gitblit v1.8.0