From 2080f2378f836d1ea8b79b8d2e3fca0665d27e1c Mon Sep 17 00:00:00 2001
From: hongji.li <hongji.a.li@capgemini.com>
Date: 星期二, 26 九月 2023 08:51:34 +0800
Subject: [PATCH] Merge branch 'feature/kevin_addsanitycheck' into dev
---
_Main/UI/MacroPlannerWebApp/Component_DialogCreateEditScenario/Method_OnOk.def | 26 ++++++++++++++++----------
1 files changed, 16 insertions(+), 10 deletions(-)
diff --git a/_Main/UI/MacroPlannerWebApp/Component_DialogCreateEditScenario/Method_OnOk.def b/_Main/UI/MacroPlannerWebApp/Component_DialogCreateEditScenario/Method_OnOk.def
index 1d0ed83..b8022af 100644
--- a/_Main/UI/MacroPlannerWebApp/Component_DialogCreateEditScenario/Method_OnOk.def
+++ b/_Main/UI/MacroPlannerWebApp/Component_DialogCreateEditScenario/Method_OnOk.def
@@ -17,6 +17,21 @@
newscenario := null( Scenario );
strategy := null( Strategy );
+ // New version
+ globalotdtable := GlobalOTDTable;
+ testbusinesstype := "闆嗗洟";
+ if( data.IsCreateNewVersion() ){
+ VersionControl::CreateNewSceneVersion( globalotdtable, testbusinesstype );
+ }else{
+ VersionControl::CopyVersion( globalotdtable, testbusinesstype );
+ }
+ versionname := VersionControl::GetVersionInfo( globalotdtable, testbusinesstype ).Element( 3 );
+
+ // Get Version Name
+ if( data.Name() = "" ){
+ data.Name( versionname );
+ }
+
// Copy scenario
if( isnull( data.WrappedInstance() ) )
{
@@ -93,17 +108,8 @@
// sync data
if( data.EnableSync() ) {
MacroPlan::DoSync( macroPlanNew,
- data.BusinessType(), data.IsKeyProduct(), data.CreatePurchaseSupplyMaterial() );
+ data.BusinessType(), data.IsKeyProduct(), data.CreatePurchaseSupplyMaterial() ,GlobalOTDTable);
}
-
- // New version
- globalotdtable := GlobalOTDTable;
- testbusinesstype := "闆嗗洟";
- if( data.IsCreateNewVersion() ){
- VersionControl::CreateNewSceneVersion( globalotdtable, testbusinesstype );
- }else{
- VersionControl::CreateNewVersion( globalotdtable, testbusinesstype );
- }
this.Close();
*]
--
Gitblit v1.9.3