Quintiq file version 2.0 
 | 
#parent: #root 
 | 
StaticMethod MenuPostponedAllowed ( 
 | 
  LibUTF_IterationRun run, 
 | 
  MacroPlan macroplan, 
 | 
  Boolean checkallowed, 
 | 
  NamedValueTree nvt_salesdemandinperiods 
 | 
) 
 | 
{ 
 | 
  TextBody: 
 | 
  [* 
 | 
    feedback_o :=''; 
 | 
    sdips := UI_SalesDemandInPeriod::FindMultiple( run, macroplan, nvt_salesdemandinperiods ); 
 | 
    allowedperiods := BaseSalesDemandInPeriod::GetAllowedPostponementPeriods( sdips ); 
 | 
    info( "allowedperiods>>", allowedperiods.Size()); 
 | 
    periods := construct( Period_MPs);  
 | 
    traverse( allowedperiods, Elements, p ) 
 | 
    { 
 | 
      // cast object to non const 
 | 
      periods.Add( p.AsMutable().astype( Period_MP ) );   
 | 
    } 
 | 
    info( "periods>>", periods.Size()) 
 | 
    allowed := SalesDemandInPeriod::CanPostpone( sdips, periods, feedback_o ) 
 | 
    text := 'SalesDemandInPeriod allowed to postponed check:' + feedback_o; 
 | 
     
 | 
    UI_Utility::ValidateTrue( run, checkallowed, allowed, text ); 
 | 
  *] 
 | 
  InterfaceProperties { Accessibility: 'Module' } 
 | 
} 
 |