From 6d6cc10d9e8e242661da7fd655dec155a09d676c Mon Sep 17 00:00:00 2001
From: haorenhui <renhui.hao@capgemini.com>
Date: 星期一, 30 十月 2023 11:41:12 +0800
Subject: [PATCH] actual关键物料判断

---
 _Main/BL/Type_MacroPlan/Method_DoASyncMappingActualPISPIPData.qbl |    7 ++++---
 1 files changed, 4 insertions(+), 3 deletions(-)

diff --git a/_Main/BL/Type_MacroPlan/Method_DoASyncMappingActualPISPIPData.qbl b/_Main/BL/Type_MacroPlan/Method_DoASyncMappingActualPISPIPData.qbl
index 4c98455..7140c64 100644
--- a/_Main/BL/Type_MacroPlan/Method_DoASyncMappingActualPISPIPData.qbl
+++ b/_Main/BL/Type_MacroPlan/Method_DoASyncMappingActualPISPIPData.qbl
@@ -36,10 +36,11 @@
         info( "Now is dealing with the " + count.AsQUILL() + "ActualPISPIP " + "( " + count.AsQUILL() + "/" + totalcount.AsQUILL() + " ) " + (count/totalcount*100).Round( 1 ).AsQUILL() + "%" );
         }
       //product := select( globalOTDTable,Global_MappingProduct_MP,product,product.ID() = actual.ProductID() and product.KeyProduct() = nuclear,true);
-      if( /*not isnull( product*/ guard( actual.Global_MAPISPIPCategory().KeyProduct() = nuclear, false ) ){
+      //if( guard( actual.Global_MAPISPIPCategory().KeyProduct() = nuclear, false ) ){
+      if( not nuclear or (nuclear and actual.Global_MAPISPIPCategory().Critical() = nuclear) ){
       if( not isnull(businessTypes)){
       
-        for( i :=0 ;i < businessTypes.Size();i++ ){
+        
           //businessType := businessTypes.Element( i );
           if( /*product.BusinessType() = businessType and not product.IsCommon()*/ not actual.Global_MAPISPIPCategory().IsCommon() ){
             ActualProductInStockingPointInPeriod::CreateOrUpdate( this,
@@ -49,7 +50,7 @@
                                                                   actual.ActualInventoryLevelEnd(),
                                                                   actual.ManufacturedDate());
           }
-        }
+        
         
       }else{
         ActualProductInStockingPointInPeriod::CreateOrUpdate( this,

--
Gitblit v1.9.3