From 135b749777d8b87f0f670794ab408d0f9bf61028 Mon Sep 17 00:00:00 2001
From: chaiyunying <chaiyunying>
Date: 星期二, 31 十月 2023 11:07:55 +0800
Subject: [PATCH] Merge branch 'dev' into dev_cyy20231026
---
_Main/BL/Type_MacroPlan/Method_DoASyncMappingActualPISPIPData.qbl | 14 ++++++++------
1 files changed, 8 insertions(+), 6 deletions(-)
diff --git a/_Main/BL/Type_MacroPlan/Method_DoASyncMappingActualPISPIPData.qbl b/_Main/BL/Type_MacroPlan/Method_DoASyncMappingActualPISPIPData.qbl
index d2f5724..7140c64 100644
--- a/_Main/BL/Type_MacroPlan/Method_DoASyncMappingActualPISPIPData.qbl
+++ b/_Main/BL/Type_MacroPlan/Method_DoASyncMappingActualPISPIPData.qbl
@@ -12,9 +12,10 @@
// renhao Aug-14-2023 (created)
listtodeal := construct( Global_MappingActualProductInStockingPointInPeriods, constcontent );
if ( businessTypes.Size() > 0 ) {
- businessTypeName := businessTypes.Element( 0 );
- targetGlobal_ProductCategory := select( globalOTDTable, Global_ProductCategory, tempGPC, tempGPC.BusinessTypeName() = businessTypeName );
- listtodeal := selectset( targetGlobal_ProductCategory, Global_MappingProduct_MP.Global_MAPISPIPCategory.Global_MappingActualProductInStockingPointInPeriod,
+ targetGlobal_ProductCategory := selectset( globalOTDTable, Global_ProductCategory, tempGPC,
+ exists( businessTypes, Elements, tempBTN, tempBTN = tempGPC.BusinessTypeName() ) );
+ listtodeal := selectset( targetGlobal_ProductCategory,
+ Elements.Global_MappingProduct_MP.Global_MAPISPIPCategory.Global_MappingActualProductInStockingPointInPeriod,
tempGMPIL,
( tempGMPIL.ActualInventoryLevelEnd() > 0 ) and
( organcodelist.Find( tempGMPIL.StockingPointID().SubString( 0, 3 ) ) >= 0 ) );
@@ -35,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,
@@ -48,7 +50,7 @@
actual.ActualInventoryLevelEnd(),
actual.ManufacturedDate());
}
- }
+
}else{
ActualProductInStockingPointInPeriod::CreateOrUpdate( this,
--
Gitblit v1.9.3