From 6dfdd89e69bd8b01d15f6fe0264bfab0ab67d2eb Mon Sep 17 00:00:00 2001
From: limj <limj@taizhitech.com>
Date: 星期日, 08 十月 2023 10:57:41 +0800
Subject: [PATCH] Merge branch 'dev' of http://47.101.211.7:10101/r/TIANMA_JITUAN into dev_lmj
---
_Main/UI/MacroPlannerWebApp/Component_DialogCreateEditScenario/Method_OnOk.def | 11 +++++++++--
1 files changed, 9 insertions(+), 2 deletions(-)
diff --git a/_Main/UI/MacroPlannerWebApp/Component_DialogCreateEditScenario/Method_OnOk.def b/_Main/UI/MacroPlannerWebApp/Component_DialogCreateEditScenario/Method_OnOk.def
index 92e4f73..b488de3 100644
--- a/_Main/UI/MacroPlannerWebApp/Component_DialogCreateEditScenario/Method_OnOk.def
+++ b/_Main/UI/MacroPlannerWebApp/Component_DialogCreateEditScenario/Method_OnOk.def
@@ -23,7 +23,7 @@
if( data.IsCreateNewVersion() ){
VersionControl::CreateNewSceneVersion( globalotdtable, testbusinesstype );
}else{
- VersionControl::CreateNewVersion( globalotdtable, testbusinesstype );
+ VersionControl::CopyVersion( globalotdtable, testbusinesstype );
}
versionname := VersionControl::GetVersionInfo( globalotdtable, testbusinesstype ).Element( 3 );
@@ -31,6 +31,13 @@
if( data.Name() = "" ){
data.Name( versionname );
}
+
+ // Get Business Type from Scenario Name
+ businesstype := select( globalotdtable,
+ BusinessType,
+ b,
+ b.ScenarioName()=data.ScenarioName() ).BusinessTypeName();
+ data.BusinessType( businesstype );
// Copy scenario
if( isnull( data.WrappedInstance() ) )
@@ -108,7 +115,7 @@
// sync data
if( data.EnableSync() ) {
MacroPlan::DoSync( macroPlanNew,
- data.BusinessType(), data.IsKeyProduct(), data.CreatePurchaseSupplyMaterial() );
+ data.BusinessType(), data.IsKeyProduct(), data.CreatePurchaseSupplyMaterial() ,GlobalOTDTable);
}
this.Close();
--
Gitblit v1.9.3