| | |
| | | // Akari Oct-30-2024 (created) |
| | | offlinePlanRow := select( offlinePlanTable,Row,row,row.ProductID() = this.ProductInStockingPoint_MP().ProductID() and row.StockingPointID() = this.ProductInStockingPoint_MP().StockingPointID() ); |
| | | |
| | | offlinePlanCells := selectset( offlinePlanRow, Cell,cell,cell.Column().TimeUnit() = "Day" ); |
| | | offlinePlanCellIndexTree := NamedValueTree::Create(); |
| | | for( i := 0; i< offlinePlanCells.Size(); i++ ){ |
| | | offlinePlanCell := offlinePlanCells.Element( i ); |
| | | offlinePlanCellHandle := offlinePlanCellIndexTree.GetHandle( offlinePlanCell.Column().StartDate().AsQUILL() ); |
| | | offlinePlanCellIndexTree.Root().AddChild( offlinePlanCellHandle,i ); |
| | | } |
| | | |
| | | |
| | | if( not this.IsEnable() ){ |
| | | if( not this.IsEnable() and not isnull( offlinePlanRow )){ |
| | | offlinePlanCells := selectset( offlinePlanRow, Cell,cell,cell.Column().TimeUnit() = "Day" ); |
| | | offlinePlanCellIndexTree := NamedValueTree::Create(); |
| | | for( i := 0; i< offlinePlanCells.Size(); i++ ){ |
| | | offlinePlanCell := offlinePlanCells.Element( i ); |
| | | offlinePlanCellHandle := offlinePlanCellIndexTree.GetHandle( offlinePlanCell.Column().StartDate().AsQUILL() ); |
| | | offlinePlanCellIndexTree.Root().AddChild( offlinePlanCellHandle,i ); |
| | | } |
| | | |
| | | this.IsEnable( true ); |
| | | |
| | | pispips := selectset( this,ProductInStockingPoint_MP.ProductInStockingPointInPeriod.astype( ProductInStockingPointInPeriodPlanningLeaf ),period,period.Period_MP().StartDate() <= this.LockDate() ); |