| | |
| | | |
| | | traverse( table,LocalRow,row ){ |
| | | traverse( table,LocalColumn,column,column.TimeUnit() = "Week"){ |
| | | baseVersionValue := sum( table,LocalRow.LocalCell.astype( LocalCell_OfflinePlanComparison ),cell, |
| | | baseVersionValue := sum( row,LocalCell.astype( LocalCell_OfflinePlanComparison ),cell, |
| | | cell.LocalColumn().TimeUnit() = "Day" and |
| | | cell.LocalColumn().CustomDate() >= column.CustomDate() and |
| | | cell.LocalColumn().CustomDate() < column.CustomDate().StartOfNextWeek(), cell.BaseVersionValue()); |
| | | compareVersionValue := sum( table,LocalRow.LocalCell.astype( LocalCell_OfflinePlanComparison ),cell, |
| | | cell.LocalColumn().CustomDate() < column.CustomDate().StartOfNextWeek(), cell.BaseVersion()); |
| | | compareVersionValue := sum( row,LocalCell.astype( LocalCell_OfflinePlanComparison ),cell, |
| | | cell.LocalColumn().TimeUnit() = "Day" and |
| | | cell.LocalColumn().CustomDate() >= column.CustomDate() and |
| | | cell.LocalColumn().CustomDate() < column.CustomDate().StartOfNextWeek(), cell.CompareVersionValue()); |
| | | cell.LocalColumn().CustomDate() < column.CustomDate().StartOfNextWeek(), cell.CompareVersion()); |
| | | |
| | | row.LocalCell(relnew,LocalCell_OfflinePlanComparison,LocalColumn := column,BaseVersionValue := baseVersionValue,CompareVersionValue := compareVersionValue ); |
| | | row.LocalCell( relnew,LocalCell_OfflinePlanComparison,LocalColumn := column,BaseVersion := baseVersionValue,CompareVersion := compareVersionValue ); |
| | | } |
| | | } |
| | | traverse( table,LocalRow,row ){ |
| | | traverse( table,LocalColumn,column,column.TimeUnit() = "Month "){ |
| | | baseVersionValue := sum( table,LocalRow.LocalCell.astype( LocalCell_OfflinePlanComparison ),cell, |
| | | traverse( table,LocalColumn,column,column.TimeUnit() = "Month"){ |
| | | baseVersionValue := sum( row,LocalCell.astype( LocalCell_OfflinePlanComparison ),cell, |
| | | cell.LocalColumn().TimeUnit() = "Day" and |
| | | cell.LocalColumn().CustomDate() >= column.CustomDate() and |
| | | cell.LocalColumn().CustomDate() < column.CustomDate().StartOfNextMonth(), cell.BaseVersionValue()); |
| | | compareVersionValue := sum( table,LocalRow.LocalCell.astype( LocalCell_OfflinePlanComparison ),cell, |
| | | cell.LocalColumn().CustomDate() < column.CustomDate().StartOfNextMonth(), cell.BaseVersion()); |
| | | compareVersionValue := sum( row,LocalCell.astype( LocalCell_OfflinePlanComparison ),cell, |
| | | cell.LocalColumn().TimeUnit() = "Day" and |
| | | cell.LocalColumn().CustomDate() >= column.CustomDate() and |
| | | cell.LocalColumn().CustomDate() < column.CustomDate().StartOfNextMonth(), cell.CompareVersionValue()); |
| | | cell.LocalColumn().CustomDate() < column.CustomDate().StartOfNextMonth(), cell.CompareVersion()); |
| | | |
| | | row.LocalCell(relnew,LocalCell_OfflinePlanComparison,LocalColumn := column,BaseVersionValue := baseVersionValue,CompareVersionValue := compareVersionValue ); |
| | | row.LocalCell( relnew,LocalCell_OfflinePlanComparison,LocalColumn := column,BaseVersion := baseVersionValue,CompareVersion := compareVersionValue ); |
| | | } |
| | | } |
| | | |
| | |
| | | localColumns := construct( LocalColumns ); |
| | | localColumnIndexTree := NamedValueTree::Create(); |
| | | traverse( this,NewOfflinePlanColumn,column,column.StartDate() >= macroPlan.StartOfPlanning().Date()){ |
| | | localColumn := table.LocalColumn( relnew,CustomDate := column.StartDate()); |
| | | localColumn := table.LocalColumn( relnew,CustomDate := column.StartDate(),TimeUnit := "Day"); |
| | | localColumnHandle := localColumnIndexTree.GetHandle( column.StartDate().AsQUILL() ); |
| | | localColumns.Add( localColumn ); |
| | | localColumnIndexTree.Root().AddChild( localColumnHandle,localColumns.Size() - 1 ); |
| | |
| | | } |
| | | } |
| | | |
| | | startDate := minselect( table,LocalColumn,localColumn,localColumn.CustomDate() ).CustomDate(); |
| | | endDate := maxselect( table,LocalColumn,localColumn,localColumn.CustomDate() ).CustomDate(); |
| | | for( i := startDate.StartOfWeek(); i <= endDate.StartOfNextWeek(); i := i.StartOfNextWeek() ){ |
| | | timeUnit := "Week"; |
| | | localColumnHandle := localColumnIndexTree.GetHandle( i.AsQUILL() + timeUnit); |
| | | localColumn := table.LocalColumn( relnew,CustomDate := i,TimeUnit := timeUnit ); |
| | | localColumns.Add( localColumn ); |
| | | localColumnIndexTree.Root().AddChild( localColumnHandle,localColumns.Size() - 1 ); |
| | | } |
| | | for( i := startDate.StartOfMonth(); i <= endDate.StartOfNextMonth(); i := i.StartOfNextMonth() ){ |
| | | timeUnit := "Month"; |
| | | localColumnHandle := localColumnIndexTree.GetHandle( i.AsQUILL() + timeUnit); |
| | | localColumn := table.LocalColumn( relnew,CustomDate := i,TimeUnit := timeUnit ); |
| | | localColumns.Add( localColumn ); |
| | | localColumnIndexTree.Root().AddChild( localColumnHandle,localColumns.Size() - 1 ); |
| | | } |
| | | traverse( table,LocalRow,row ){ |
| | | traverse( table,LocalColumn,column,column.TimeUnit() = "Week"){ |
| | | actual := sum( row,LocalCell.astype( LocalCell_ProductionComparison ),cell, |
| | | cell.LocalColumn().TimeUnit() = "Day" and |
| | | cell.LocalColumn().CustomDate() >= column.CustomDate() and |
| | | cell.LocalColumn().CustomDate() < column.CustomDate().StartOfNextWeek(), cell.Actual()); |
| | | plan := sum( row,LocalCell.astype( LocalCell_ProductionComparison ),cell, |
| | | cell.LocalColumn().TimeUnit() = "Day" and |
| | | cell.LocalColumn().CustomDate() >= column.CustomDate() and |
| | | cell.LocalColumn().CustomDate() < column.CustomDate().StartOfNextWeek(), cell.Plan()); |
| | | |
| | | row.LocalCell( relnew,LocalCell_ProductionComparison,LocalColumn := column,Actual := actual,Plan := plan ); |
| | | } |
| | | } |
| | | traverse( table,LocalRow,row ){ |
| | | traverse( table,LocalColumn,column,column.TimeUnit() = "Month"){ |
| | | actual := sum( row,LocalCell.astype( LocalCell_ProductionComparison ),cell, |
| | | cell.LocalColumn().TimeUnit() = "Day" and |
| | | cell.LocalColumn().CustomDate() >= column.CustomDate() and |
| | | cell.LocalColumn().CustomDate() < column.CustomDate().StartOfNextMonth(), cell.Actual()); |
| | | plan := sum( row,LocalCell.astype( LocalCell_ProductionComparison ),cell, |
| | | cell.LocalColumn().TimeUnit() = "Day" and |
| | | cell.LocalColumn().CustomDate() >= column.CustomDate() and |
| | | cell.LocalColumn().CustomDate() < column.CustomDate().StartOfNextMonth(), cell.Plan()); |
| | | |
| | | row.LocalCell( relnew,LocalCell_ProductionComparison,LocalColumn := column,Actual := actual,Plan := plan ); |
| | | } |
| | | } |
| | | |
| | | return table; |
| | | *] |
| | | } |
| | |
| | | Properties: |
| | | [ |
| | | DataType: 'LocalTable' |
| | | FilterArguments: 'startDate:QMacroPlanner::FormOfflinePlanComparison.dhStartDate;endDate:QMacroPlanner::FormOfflinePlanComparison.dhEndDate' |
| | | FixedFilter: 'not object.IsAttrbuteColumn() and startDate <= object.Date() and endDate > object.Date()' |
| | | FilterArguments: 'startDate:QMacroPlanner::FormOfflinePlanComparison.dhStartDate;endDate:QMacroPlanner::FormOfflinePlanComparison.dhEndDate;timeUnit:QMacroPlanner::FormOfflinePlanComparison.dhTimeUnit' |
| | | FixedFilter: 'not object.IsAttrbuteColumn() and startDate <= object.Date() and endDate > object.Date() and object.TimeUnit() = timeUnit' |
| | | Source: 'dhTable' |
| | | Taborder: 0 |
| | | Transformation: 'LocalColumn' |
| | |
| | | [ |
| | | DataBinding: 'ddlOfflinePlanTable.Data.TableName' |
| | | NumberOfColumns: 50 |
| | | Taborder: 4 |
| | | Taborder: 6 |
| | | ] |
| | | } |
| | | Component bExport id:bExport_298 |
| | |
| | | Properties: |
| | | [ |
| | | Image: 'EXPORT1' |
| | | Taborder: 2 |
| | | Taborder: 4 |
| | | ] |
| | | } |
| | | Component dhXMLDataListener id:dhXMLDataListener_273 |
| | |
| | | ] |
| | | Properties: |
| | | [ |
| | | Taborder: 5 |
| | | ] |
| | | } |
| | | Component rbgTimeUnit |
| | | { |
| | | #keys: '[414996.1.147730565]' |
| | | BaseType: 'WebRadioButtonGroup' |
| | | Properties: |
| | | [ |
| | | BoundValue: 'Day' |
| | | ButtonLabels: 'Day;Week;Month' |
| | | ButtonValues: 'Day;Week;Month' |
| | | Taborder: 2 |
| | | ] |
| | | } |
| | | Component dhTimeUnit |
| | | { |
| | | #keys: '[414996.1.147730603]' |
| | | BaseType: 'WebDataHolder' |
| | | Databinding: 'String*' |
| | | Properties: |
| | | [ |
| | | Taborder: 3 |
| | | ] |
| | | } |
对比新文件 |
| | |
| | | Quintiq file version 2.0 |
| | | #parent: PanelRibbon504/dhTimeUnit |
| | | Response OnCreated () id:Response_PanelRibbon504_801_dhTimeUnit_OnCreated |
| | | { |
| | | #keys: '[414996.1.147730601]' |
| | | CanBindMultiple: false |
| | | DefinitionID: 'Responsedef_WebComponent_OnCreated' |
| | | GroupServerCalls: true |
| | | QuillAction |
| | | { |
| | | Body: |
| | | [* |
| | | this.Data( "Day" ); |
| | | *] |
| | | } |
| | | } |
对比新文件 |
| | |
| | | Quintiq file version 2.0 |
| | | #parent: PanelRibbon504/rbgTimeUnit |
| | | Response OnUserChanged () id:Response_PanelRibbon504_801_rbgTimeUnit_OnUserChanged |
| | | { |
| | | #keys: '[414996.1.147730564]' |
| | | CanBindMultiple: false |
| | | DefinitionID: 'Responsedef_WebRadioButtonGroup_OnUserChanged' |
| | | GroupServerCalls: true |
| | | QuillAction |
| | | { |
| | | Body: |
| | | [* |
| | | dhTimeUnit.Data( this.BoundValue() ); |
| | | *] |
| | | } |
| | | } |