From 5655862ec81022848c46d1862404f077b919f9fa Mon Sep 17 00:00:00 2001
From: xiaoding721 <33130084+xiaoding721@users.noreply.github.com>
Date: 星期四, 12 九月 2024 12:55:32 +0800
Subject: [PATCH] 添加新增Forecast的时候可以使用Curve拆分的功能

---
 _Main/BL/Type_Archive/StaticMethod_GenerateForecast.qbl |    9 ++++++---
 1 files changed, 6 insertions(+), 3 deletions(-)

diff --git a/_Main/BL/Type_Archive/StaticMethod_GenerateForecast.qbl b/_Main/BL/Type_Archive/StaticMethod_GenerateForecast.qbl
index c2e0f8d..fc1beab 100644
--- a/_Main/BL/Type_Archive/StaticMethod_GenerateForecast.qbl
+++ b/_Main/BL/Type_Archive/StaticMethod_GenerateForecast.qbl
@@ -2,13 +2,16 @@
 #parent: #root
 StaticMethod GenerateForecast (
   ArchiveExecutionStatus archiveExecutionStatus,
-  MacroPlan macroPlan
+  MacroPlan macroPlan,
+  Boolean isClearForecast
 )
 {
   TextBody:
   [*
-    traverse ( macroPlan, SalesDemand.astype( Forecast ), f ) {
-      f.Delete();
+    if( isClearForecast ){
+      traverse ( macroPlan, SalesDemand.astype( Forecast ), f ) {
+        f.Delete();
+      }
     }
     
     productMPs := selectset( macroPlan,Product_MP,prod,not prod.IsSystem() );

--
Gitblit v1.9.3