From fa779ca32d3c809f6d67b5fd6d17d358c34ef6a4 Mon Sep 17 00:00:00 2001 From: ruanqi Date: Mon, 3 Mar 2025 14:22:05 +0800 Subject: [PATCH] =?UTF-8?q?0412=E6=9B=B4=E6=96=B0?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../mapper/production/DailyPlanMapper.xml | 21 ++++++++++--------- 1 file changed, 11 insertions(+), 10 deletions(-) diff --git a/src/main/resources/mapper/production/DailyPlanMapper.xml b/src/main/resources/mapper/production/DailyPlanMapper.xml index c62c712..139e84c 100644 --- a/src/main/resources/mapper/production/DailyPlanMapper.xml +++ b/src/main/resources/mapper/production/DailyPlanMapper.xml @@ -8,8 +8,8 @@ select a.site, a.OrderNo,a.PartNo,a.Status,a.PlanStartDate,a.NeedDate,a.LotSize,a.EnterDate,a.UserName,a.MaterialSplitFlag,a.RepairSOFlag, P.Spec+'/'+isnull(P.PartDescription,'') PartDescription,P.Spec,isnull(SL.scheduledQty,0) as scheduledQty,s.workCenterNo,S.qtyReported,S.qtyApprove,S.machSetupTime, - S.machRunFactor,S.factorUnit,S.ItemNo,S.OperationDesc,s.Efficiency,isnull(SOP.TotalFinishedQty,0) lastApproveQty,dbo.Get_PartWeightFactorForReport(a.site,a.PartNo,a.OrderNo) weightFactor, - Round(dbo.Get_PartWeightFactorForReport(a.site,a.PartNo,a.OrderNo)*a.LotSize,2) weight,dbo.Get_PartPlanQty(a.site,a.PartNo,a.OrderNo) partPlanQty,cod.PlanShipDate, + S.machRunFactor,S.factorUnit,S.ItemNo,S.OperationDesc,s.Efficiency,isnull(SOP.TotalFinishedQty,0) lastApproveQty,P.NetWeight/1000 weightFactor, + Round(isnull(P.NetWeight/1000,1)*a.LotSize,2) weight,dbo.Get_PartPlanQty(a.site,a.PartNo,a.OrderNo) partPlanQty,cod.PlanShipDate, dbo.Get_LastStartTime( a.site, a.OrderNo,S.ItemNo) LastStartDate,Round(S.DefectiveQty,3) DefectiveQty,dbo.Get_PartValue( a.site,a.PartNo,'CURING METHOD') cuiHuaJi, Round((a.LotSize- S.qtyReported)/case when s.MachRunFactor=0 then 1000000 else s.MachRunFactor end ,1) lastTime ,dbo.Get_E_OriginalOrderTypeDesc(a.site, a.OrderNo) orderTypeDesc @@ -292,7 +292,8 @@ and a.E_Levels = #{eLevels} - order by a.PlanStartDate desc,s.itemNo + order by case when dbo.Get_E_OriginalOrderTypeDesc(a.site, a.OrderNo) in ('变更订单','加急订单') then 1 else 2 end , + a.PlanStartDate desc,s.itemNo update SOTaskOrderHeader set CombineTime = GetDate() where site=#{site} and orderNo=#{orderNo} @@ -366,8 +367,8 @@