From a5d4d31310d9792243db3ca06080a5f8b83b542c Mon Sep 17 00:00:00 2001
From: lazhen <17772815105@139.com>
Date: 星期三, 21 八月 2024 10:09:41 +0800
Subject: [PATCH] Merge branch 'dev' of http://47.101.211.7:10101/r/VWED into dev-zlg

---
 _Main/BL/Type_LocalCell_ScheduleSummary/StaticMethod_CreateFullTable.qbl |   26 ++++++++++++++++----------
 1 files changed, 16 insertions(+), 10 deletions(-)

diff --git a/_Main/BL/Type_LocalCell_ScheduleSummary/StaticMethod_CreateFullTable.qbl b/_Main/BL/Type_LocalCell_ScheduleSummary/StaticMethod_CreateFullTable.qbl
index f3fb6c4..557d70d 100644
--- a/_Main/BL/Type_LocalCell_ScheduleSummary/StaticMethod_CreateFullTable.qbl
+++ b/_Main/BL/Type_LocalCell_ScheduleSummary/StaticMethod_CreateFullTable.qbl
@@ -3,20 +3,14 @@
 StaticMethod CreateFullTable (
   const MacroPlans owners,
   RecycleBin recycleBin,
-  const Archive archive
+  const Archive archive,
+  const MacroPlan owner
 ) as LocalTable
 {
   TextBody:
   [*
     // rislai Aug-7-2024 (created)
-    tables := construct( MP_Tables );
-    traverse( owners,Elements,owner ){
-      table := select( owner,MP_Table,table,table.Name() = MP_Cell_ScheduleSummary::GetTableName() ); 
-      if( isnull( table )){
-        table :=  MP_Cell_ScheduleSummary::Create( owner );
-      }
-      tables.Add( table );
-    }
+    tables := MP_Table::GetMP_Tables_ScheduleSummary( owners );
     
     scheduleSummaryOutputDataIndexTree := NamedValueTree::Create();
     scheduleSummaryOutputDatas := selectset( archive,ScheduleSummaryOutputLine.ScheduleSummaryOutputData,data,
@@ -42,7 +36,7 @@
        localColumnIndexTree.Root().AddChild( localColumnHandle,localColumns.Size() - 1 );
     }
     traverse( tables,Elements.MP_Row,row ){
-    
+     
        localRow := localTable.LocalRow( relnew,CustomName := row.Name(),Index := localTable.GetRowIndexCache() );
     
        traverse( localColumns,Elements,localColumn ){
@@ -88,6 +82,18 @@
        }
     }
     
+    //startDate := owner.StartOfPlanning().Date() + 7;
+    //endDate := maxselect( owner,Unit.UnitPeriod.astype( UnitPeriodTime ).Period_MP,period,period.EndDate(),period.TimeUnit() = "Month" ).EndDate();
+    //columns := construct( MP_Columns );
+    //columnIndexTree := NamedValueTree::Create();
+    //for( i := startDate;i < endDate; i := i + 1){
+    //  column := table.MP_Column( relnew,CustomDate := i );
+    //  columnHandle := columnIndexTree.GetHandle( i.AsQUILL() );
+    //  columns.Add( column );
+    //  columnIndexTree.Root().AddChild( columnHandle,columns.Size() - 1 );
+    //}
+    
+    
     return localTable;
   *]
 }

--
Gitblit v1.9.3