Quintiq file version 2.0
#parent: ListTransportAvailabilities
Response OnClick () id:Response_ListTransportAvailabilities_MenuNewTransportCapacity_OnClick
{
  #keys: '[113694.0.1523580609]'
  Body:
  [*
    // Create new transport availability
    
    dlg := construct( DialogCreateEditTransportAvailability );
    tc := dlg.NewTransportAvailability( this );
    
    ApplicationLibMacroPlanner.AutoExpandSelection( this, tc );
  *]
  CanBindMultiple: false
  DefinitionID => /ListTransportAvailabilities/Responsedef_ListTransportAvailabilities_Menu_OnClick
  Initiator: 'MenuNewTransportCapacity'
  Precondition:
  [*
    return MacroPlan::HasMacroPlan( MacroPlan, feedback )
           and TransportAvailability::CanCreate( MacroPlan, feedback )
           and TransportAvailability::CanCreate( feedback, DataHolderChildUnits.Data() )
           and PeriodSpecification_MP::HasPeriodSpecification( MacroPlan, feedback )
           and Period_MP::HasPeriod( feedback, MacroPlan );
  *]
  UserRequiresReadWrite: true
}
