From e4724fcc72232d94e939d39a51234ce89b8c61e3 Mon Sep 17 00:00:00 2001
From: rislai <risheng.lai@capgemini.com>
Date: 星期五, 21 六月 2024 16:20:17 +0800
Subject: [PATCH] 修改GeneralExcelImportAndExportDataSource的存储位置
---
_Main/BL/Relations/Relation_GeneralExcelImportAndExportDataSource_RecycleBin_RecycleBin_General.qbl | 23 +++++++++++
_Main/BL/Type_ArchivePR/Method_Load.qbl | 8 +---
_Main/UI/MacroPlannerWebApp/Component_Form989/Response_pHeader_bImport_OnClick.def | 2
/dev/null | 23 -----------
_Main/BL/Type_GeneralExcelImportAndExportDataSource/StaticMethod_Upload.qbl | 4 +-
_Main/BL/Type_ArchivePR/StaticMethod_Compared.qbl | 10 ++--
_Main/UI/MacroPlannerWebApp/Component_FormPR_PP_Budget/Response_pHeader_bImport_OnClick.def | 2
_Main/UI/MacroPlannerWebApp/Component_FormSixDigitCode/Response_pHeader_393_bImport_OnClick.def | 2
8 files changed, 35 insertions(+), 39 deletions(-)
diff --git a/_Main/BL/Relations/Relation_GeneralExcelImportAndExportDataSource_Archive_Archive_GeneralExcelI.qbl b/_Main/BL/Relations/Relation_GeneralExcelImportAndExportDataSource_Archive_Archive_GeneralExcelI.qbl
deleted file mode 100644
index 7f5ef9c..0000000
--- a/_Main/BL/Relations/Relation_GeneralExcelImportAndExportDataSource_Archive_Archive_GeneralExcelI.qbl
+++ /dev/null
@@ -1,23 +0,0 @@
-Quintiq file version 2.0
-#parent: #root
-Relation GeneralExcelImportAndExportDataSource_Archive_Archive_GeneralExcelImportAndExportDataSource
-{
- #keys: '1[413988.0.1161870117]'
- DefaultRelationStrategy
- {
- }
- RelationSide.LeftSide Archive
- {
- #keys: '3[413988.0.1161870119][413988.0.1161870118][413988.0.1161870120]'
- Cardinality: '0to1'
- ObjectDefinition: GeneralExcelImportAndExportDataSource
- OwningSide: 'Reference'
- }
- RelationSide.RightSide GeneralExcelImportAndExportDataSource
- {
- #keys: '3[413988.0.1161870122][413988.0.1161870121][413988.0.1161870123]'
- Cardinality: '1toN'
- ObjectDefinition: Archive
- OwningSide: 'Owned'
- }
-}
diff --git a/_Main/BL/Relations/Relation_GeneralExcelImportAndExportDataSource_RecycleBin_RecycleBin_General.qbl b/_Main/BL/Relations/Relation_GeneralExcelImportAndExportDataSource_RecycleBin_RecycleBin_General.qbl
new file mode 100644
index 0000000..d09c664
--- /dev/null
+++ b/_Main/BL/Relations/Relation_GeneralExcelImportAndExportDataSource_RecycleBin_RecycleBin_General.qbl
@@ -0,0 +1,23 @@
+Quintiq file version 2.0
+#parent: #root
+Relation GeneralExcelImportAndExportDataSource_RecycleBin_RecycleBin_GeneralExcelImportAndExportDataSource
+{
+ #keys: '1[412672.0.1087854694]'
+ DefaultRelationStrategy
+ {
+ }
+ RelationSide.LeftSide RecycleBin
+ {
+ #keys: '3[412672.0.1087854696][412672.0.1087854695][412672.0.1087854697]'
+ Cardinality: '0to1'
+ ObjectDefinition: GeneralExcelImportAndExportDataSource
+ OwningSide: 'Reference'
+ }
+ RelationSide.RightSide GeneralExcelImportAndExportDataSource
+ {
+ #keys: '3[412672.0.1087854699][412672.0.1087854698][412672.0.1087854700]'
+ Cardinality: '1toN'
+ ObjectDefinition: RecycleBin
+ OwningSide: 'Owned'
+ }
+}
diff --git a/_Main/BL/Type_ArchivePR/Method_Load.qbl b/_Main/BL/Type_ArchivePR/Method_Load.qbl
index 551358d..e116a1e 100644
--- a/_Main/BL/Type_ArchivePR/Method_Load.qbl
+++ b/_Main/BL/Type_ArchivePR/Method_Load.qbl
@@ -1,7 +1,6 @@
Quintiq file version 2.0
#parent: #root
Method Load (
- Archive archive,
LocalTable localTable
) const
{
@@ -9,10 +8,7 @@
[*
// rislai Jun-20-2024 (created)
file := OSFile::Construct();
- //originRow := localTable.LocalRow( relnew ,Index := localTable.GetRowIndexCache());
- //carTypeRow := localTable.LocalRow( relnew ,Index := localTable.GetRowIndexCache());
- //productRow := localTable.LocalRow( relnew ,Index := localTable.GetRowIndexCache());
- //fourDigitRow := localTable.LocalRow( relnew,Index := localTable.GetRowIndexCache());
+ recycleBin := localTable.RecycleBin();
columns := selectset( localTable,LocalColumn,column,true );
columnTree := NamedValueTree::Create();
@@ -26,7 +22,7 @@
file.Open( this.FilePath(), "Read", false );
webFileBinaryData := file.ReadBinary();
- generalExcelImportAndExportDataSource := GeneralExcelImportAndExportDataSource::Upload( archive, webFileBinaryData, this.Name() );
+ generalExcelImportAndExportDataSource := GeneralExcelImportAndExportDataSource::Upload( recycleBin, webFileBinaryData, this.Name() );
generalExcelImportAndExportDataSource.ReadStructure();
selections := selectset( generalExcelImportAndExportDataSource, GeneralExcelImportAndExportDataTable, tempGEIAEDT, true );
if( selections.Size() <> 0 ){
diff --git a/_Main/BL/Type_ArchivePR/StaticMethod_Compared.qbl b/_Main/BL/Type_ArchivePR/StaticMethod_Compared.qbl
index 9f8f987..a6be942 100644
--- a/_Main/BL/Type_ArchivePR/StaticMethod_Compared.qbl
+++ b/_Main/BL/Type_ArchivePR/StaticMethod_Compared.qbl
@@ -2,19 +2,19 @@
#parent: #root
StaticMethod Compared (
RecycleBin recycleBin,
- ArchivePR baseVersion,
- ArchivePR compareVersion
+ const ArchivePR baseVersion,
+ const ArchivePR compareVersion
) as LocalTable
{
TextBody:
[*
// rislai Jun-20-2024 (created)
- archive := baseVersion.Archive(); // archive涓嶅彲璁剧疆涓哄彧璇�
+ // archive := baseVersion.Archive(); // archive涓嶅彲璁剧疆涓哄彧璇�
table := recycleBin.LocalTable( relnew );
- baseVersion.Load( archive,table );
- compareVersion.Load( archive,table );
+ baseVersion.Load( table );
+ compareVersion.Load( table );
return table;
*]
diff --git a/_Main/BL/Type_GeneralExcelImportAndExportDataSource/StaticMethod_Upload.qbl b/_Main/BL/Type_GeneralExcelImportAndExportDataSource/StaticMethod_Upload.qbl
index be13358..fed039d 100644
--- a/_Main/BL/Type_GeneralExcelImportAndExportDataSource/StaticMethod_Upload.qbl
+++ b/_Main/BL/Type_GeneralExcelImportAndExportDataSource/StaticMethod_Upload.qbl
@@ -1,7 +1,7 @@
Quintiq file version 2.0
#parent: #root
StaticMethod Upload (
- Archive archive,
+ RecycleBin recycleBin,
BinaryValue binaryValue,
String filePath
) const as GeneralExcelImportAndExportDataSource
@@ -10,7 +10,7 @@
[*
fileName := filePath.Tokenize( "\" ).Element( filePath.Tokenize( "\" ).Size() - 1 );
- generalExcelImportAndExportDataSource := archive.GeneralExcelImportAndExportDataSource( relnew,
+ generalExcelImportAndExportDataSource := recycleBin.GeneralExcelImportAndExportDataSource( relnew,
FileBinaryValue := binaryValue,
Name := fileName,
IsXLSX := fileName.EndsWith( "xlsx" ),
diff --git a/_Main/UI/MacroPlannerWebApp/Component_Form989/Response_pHeader_bImport_OnClick.def b/_Main/UI/MacroPlannerWebApp/Component_Form989/Response_pHeader_bImport_OnClick.def
index 9f14d31..30c68ea 100644
--- a/_Main/UI/MacroPlannerWebApp/Component_Form989/Response_pHeader_bImport_OnClick.def
+++ b/_Main/UI/MacroPlannerWebApp/Component_Form989/Response_pHeader_bImport_OnClick.def
@@ -24,7 +24,7 @@
webFileBinaryData := BinaryData::FromBase64EncodedString( base64String ).AsBinaryValue();
- generalExcelImportAndExportDataSource := GeneralExcelImportAndExportDataSource::Upload( Archive, webFileBinaryData, fileName );
+ generalExcelImportAndExportDataSource := GeneralExcelImportAndExportDataSource::Upload( RecycleBin, webFileBinaryData, fileName );
generalExcelImportAndExportDataSource.ReadStructure();
selection := select( generalExcelImportAndExportDataSource, GeneralExcelImportAndExportDataTable, tempGEIAEDT, tempGEIAEDT.Name() = "Sheet1" );
diff --git a/_Main/UI/MacroPlannerWebApp/Component_FormPR_PP_Budget/Response_pHeader_bImport_OnClick.def b/_Main/UI/MacroPlannerWebApp/Component_FormPR_PP_Budget/Response_pHeader_bImport_OnClick.def
index 41b869f..0f2be2a 100644
--- a/_Main/UI/MacroPlannerWebApp/Component_FormPR_PP_Budget/Response_pHeader_bImport_OnClick.def
+++ b/_Main/UI/MacroPlannerWebApp/Component_FormPR_PP_Budget/Response_pHeader_bImport_OnClick.def
@@ -24,7 +24,7 @@
webFileBinaryData := BinaryData::FromBase64EncodedString( base64String ).AsBinaryValue();
- generalExcelImportAndExportDataSource := GeneralExcelImportAndExportDataSource::Upload( Archive, webFileBinaryData, fileName );
+ generalExcelImportAndExportDataSource := GeneralExcelImportAndExportDataSource::Upload( RecycleBin, webFileBinaryData, fileName );
generalExcelImportAndExportDataSource.ReadStructure();
selection := select( generalExcelImportAndExportDataSource, GeneralExcelImportAndExportDataTable, tempGEIAEDT, tempGEIAEDT.Name() = "Sheet1" );
diff --git a/_Main/UI/MacroPlannerWebApp/Component_FormSixDigitCode/Response_pHeader_393_bImport_OnClick.def b/_Main/UI/MacroPlannerWebApp/Component_FormSixDigitCode/Response_pHeader_393_bImport_OnClick.def
index 785331d..4aa2ab6 100644
--- a/_Main/UI/MacroPlannerWebApp/Component_FormSixDigitCode/Response_pHeader_393_bImport_OnClick.def
+++ b/_Main/UI/MacroPlannerWebApp/Component_FormSixDigitCode/Response_pHeader_393_bImport_OnClick.def
@@ -24,7 +24,7 @@
webFileBinaryData := BinaryData::FromBase64EncodedString( base64String ).AsBinaryValue();
- generalExcelImportAndExportDataSource := GeneralExcelImportAndExportDataSource::Upload( Archive, webFileBinaryData, fileName );
+ generalExcelImportAndExportDataSource := GeneralExcelImportAndExportDataSource::Upload( RecycleBin, webFileBinaryData, fileName );
generalExcelImportAndExportDataSource.ReadStructure();
selection := select( generalExcelImportAndExportDataSource, GeneralExcelImportAndExportDataTable, tempGEIAEDT, tempGEIAEDT.Name() = "Sheet1" );
--
Gitblit v1.9.3