From 20470cd32eaebc49c5b8eea0e1908743846ade67 Mon Sep 17 00:00:00 2001
From: admin <admin@admin.com>
Date: 星期四, 05 九月 2024 17:26:55 +0800
Subject: [PATCH] 修复一些bug
---
_Main/BL/Type_Archive/StaticMethod_Archive.qbl | 3 ++-
_Main/BL/Type_Test/StaticMethod_Test.qbl | 17 ++---------------
_Main/BL/Type_Archive/StaticMethod_GenerateForecast.qbl | 9 ++++++++-
3 files changed, 12 insertions(+), 17 deletions(-)
diff --git a/_Main/BL/Type_Archive/StaticMethod_Archive.qbl b/_Main/BL/Type_Archive/StaticMethod_Archive.qbl
index 048216a..d395b90 100644
--- a/_Main/BL/Type_Archive/StaticMethod_Archive.qbl
+++ b/_Main/BL/Type_Archive/StaticMethod_Archive.qbl
@@ -15,7 +15,7 @@
archiveFileJSONs := respJSON.Get( "archiveFiles" );
info( archiveFileJSONs.AsString() );
- if ( code = 200 ) {
+ if ( code = 200 or code = 201 ) {
for ( i := 0; i < archiveFileJSONs.Size(); i++ ) {
archiveFileJSON := archiveFileJSONs.Get( i );
@@ -57,6 +57,7 @@
// 瀛樻。Curve
if ( curveFileName <> "" and curveBinaryValue.Size() > 0 ) {
+ info( "瀛樻。Curve锛�" + curveFileName );
ac := select( archive, ArchiveCurve, tempAC, true );
if ( not isnull( ac ) ) {
ac.Delete();
diff --git a/_Main/BL/Type_Archive/StaticMethod_GenerateForecast.qbl b/_Main/BL/Type_Archive/StaticMethod_GenerateForecast.qbl
index a363c8e..822c41f 100644
--- a/_Main/BL/Type_Archive/StaticMethod_GenerateForecast.qbl
+++ b/_Main/BL/Type_Archive/StaticMethod_GenerateForecast.qbl
@@ -12,7 +12,11 @@
}
traverse ( archiveExecutionStatus, TemporaryDemandData, tdd ,tdd.Origin() = "" or tdd.StartDate() >= macroPlan.StartOfPlanning().Date()) {
- targetProduct_MP := select( macroPlan, Product_MP, tempPMP, tempPMP.ID() = tdd.ProductID() );
+ targetProduct_MP := select( macroPlan, Product_MP, tempPMP, tempPMP.Notes() = tdd.ProductID() );
+ if( isnull( targetProduct_MP )){
+ targetProduct_MP := select( macroPlan, Product_MP, tempPMP, tempPMP.ID() = tdd.ProductID() );
+ }
+ // targetProduct_MP := select( macroPlan, Product_MP, tempPMP, tempPMP.Notes() = tdd.ProductID() );
targetStockingPoint_MP := select( macroPlan, StockingPoint_MP, tempSPMP, tempSPMP.ID() = tdd.StockingPointID() );
// info( tdd.SalesSegmentName() );
if ( not isnull( targetProduct_MP ) and not isnull( targetStockingPoint_MP ) ) {
@@ -32,6 +36,9 @@
false );
forcest.Origin( tdd.Origin() );
}
+ if( isnull( targetProduct_MP )){
+ info( tdd.ProductID() + " -> 鏈壘鍒�" );
+ }
}
*]
}
diff --git a/_Main/BL/Type_Test/StaticMethod_Test.qbl b/_Main/BL/Type_Test/StaticMethod_Test.qbl
index a1d7e18..6e9e87a 100644
--- a/_Main/BL/Type_Test/StaticMethod_Test.qbl
+++ b/_Main/BL/Type_Test/StaticMethod_Test.qbl
@@ -10,21 +10,8 @@
{
TextBody:
[*
- archive.ArchivePP( relflush );
- archive.ArchiveBudget( relflush );
+ prod := select( macroPlan,Product_MP,prod,prod.Notes() = "06R100012A" );
- archive.ArchivePP( relnew,Name := "2025 M" )
- archive.ArchivePP( relnew,Name := "2025 W" )
- archive.ArchivePP( relnew,Name := "2026 M" )
- archive.ArchivePP( relnew,Name := "2026 W" )
- archive.ArchivePP( relnew,Name := "2027 M" )
- archive.ArchivePP( relnew,Name := "2027 W" )
-
- archive.ArchiveBudget( relnew,Name := "2025 M" )
- archive.ArchiveBudget( relnew,Name := "2025 W" )
- archive.ArchiveBudget( relnew,Name := "2026 M" )
- archive.ArchiveBudget( relnew,Name := "2026 W" )
- archive.ArchiveBudget( relnew,Name := "2027 M" )
- archive.ArchiveBudget( relnew,Name := "2027 W" )
+ error( prod.ID() );
*]
}
--
Gitblit v1.9.3