diff --git a/src/main/resources/mapper/board/BoardMapper.xml b/src/main/resources/mapper/board/BoardMapper.xml index fa2def1..e20dcd4 100644 --- a/src/main/resources/mapper/board/BoardMapper.xml +++ b/src/main/resources/mapper/board/BoardMapper.xml @@ -122,7 +122,7 @@ LEFT JOIN SOScheduledRouting SOP ON SOP.site=t.site and SOP.OrderNo=t.OrderNo and SOP.SeqNo = isnull(T.PreviousSeqNo,-1) ,SORouting a left join ShopOrder b on a.site=b.site and a.orderNo=b.orderNo - where T.Site = A.Site AND T.OrderNo = A.OrderNo AND T.ItemNo = A.ItemNo AND T.ClosedFlag = 'N' AND T.OutWorkFlag = 'Y' + where T.Site = A.Site AND T.OrderNo = A.OrderNo AND T.ItemNo = A.ItemNo AND T.ClosedFlag = 'N' AND (T.OutWorkFlag = 'N' OR t.S_ScheduledDate=cast(GetDate() as Date) ) and dbo.Get_WorkCenter_ProLineNo(a.site,a.WorkCenterNo)='TRIMMING' and b.status!='已关闭' and b.status!='已取消' and b.enterDate>'2022-01-01' @@ -147,7 +147,7 @@ left join ShopOrder b on a.site=b.site and a.orderNo=b.orderNo LEFT JOIN SORoutingOutput SOP ON a.site=SOP.site and a.OrderNo=SOP.OrderNo and SOP.itemNo=dbo.Get_SORouting_PreviousOperationItemNo(a.site,a.OrderNo,a.itemNo) Left Join PartSubPropertiesValue as S90 On S90.Site=a.Site and S90.PartNo=a.PartNo and S90.PropertiesItemNo='SPECIAL CHECK' - where T.Site = A.Site AND T.OrderNo = A.OrderNo AND T.ItemNo = A.ItemNo AND T.ClosedFlag = 'N' AND T.OutWorkFlag = 'Y' + where T.Site = A.Site AND T.OrderNo = A.OrderNo AND T.ItemNo = A.ItemNo AND T.ClosedFlag = 'N' AND (T.OutWorkFlag = 'N' OR t.S_ScheduledDate=cast(GetDate() as Date) ) and b.status!='已关闭' and b.status!='已取消' and dbo.Get_WorkCenter_ProLineNo(a.site,a.WorkCenterNo)='INSPECT' and b.enterDate>'2022-01-01' @@ -177,7 +177,7 @@ Left Join PartSubPropertiesValue as S92 On S92.Site=a.Site and S92.PartNo=a.PartNo and S92.RecordType='P' and S92.SubCodeSeqNo=1 and S92.PropertiesItemNo='POST CURE-TEMP' Left Join PartSubPropertiesValue as S93 On S93.Site=a.Site and S93.PartNo=a.PartNo and S93.RecordType='P' and S93.SubCodeSeqNo=1 and S93.PropertiesItemNo='POST CURE-TIME' LEFT JOIN PartSubPropertiesValue p3 on p3.site=a.site and p3.PartNo=a.PartNo and p3.PropertiesItemNo='MATERIAL' - where T.Site = A.Site AND T.OrderNo = A.OrderNo AND T.ItemNo = A.ItemNo AND T.ClosedFlag = 'N' AND T.OutWorkFlag = 'Y' + where T.Site = A.Site AND T.OrderNo = A.OrderNo AND T.ItemNo = A.ItemNo AND T.ClosedFlag = 'N' AND (T.OutWorkFlag = 'N' OR t.S_ScheduledDate=cast(GetDate() as Date) ) and a.partNo like 'FP%' and b.status!='已关闭' and b.status!='已取消' and dbo.Get_WorkCenter_ProLineNo(a.site,a.WorkCenterNo)='TREAT' @@ -204,7 +204,7 @@ LEFT JOIN PartSubPropertiesValue p2 on p2.site=a.site and p2.PartNo=a.PartNo and p2.PropertiesItemNo='QTY' LEFT JOIN PartSubPropertiesValue p3 on p3.site=a.site and p3.PartNo=a.PartNo and p3.PropertiesItemNo='CARTON' LEFT JOIN PartSubPropertiesValue p4 on p4.site=a.site and p4.PartNo=a.PartNo and p4.PropertiesItemNo='BAG TYPE' - where T.Site = A.Site AND T.OrderNo = A.OrderNo AND T.ItemNo = A.ItemNo AND T.ClosedFlag = 'N' AND T.OutWorkFlag = 'Y' + where T.Site = A.Site AND T.OrderNo = A.OrderNo AND T.ItemNo = A.ItemNo AND T.ClosedFlag = 'N' AND (T.OutWorkFlag = 'N' OR t.S_ScheduledDate=cast(GetDate() as Date) ) AND a.partNo like 'FP%' and dbo.Get_WorkCenter_ProLineNo(a.site,a.WorkCenterNo)='PACKING' and b.status!='已关闭' and b.status!='已取消'