Quintiq file version 2.0 #parent: ListSalesDemand Response OnClick ( structured[SalesDemandBase] selection ) id:Response_ListSalesDemand_MenuSmartPlan_OnClick { #keys: '[124808.2.297672613]' Body: [* // Smart plan for PISPIPs in sales demands dlg := construct( DialogSmartPlan ); isviableonestepupstream := false; dlg.SmartPlan( selection, this, isviableonestepupstream ); *] CanBindMultiple: false DefinitionID => /ListSalesDemand/Responsedef_ListSalesDemand_Menu_OnClick Initiator: 'MenuSmartPlan' Precondition: [* forecasts := selectset( selection, Elements.astype( Forecast ), forecast, true ); return MacroPlan.CanPlan( feedback ) and Forecast::CanPlan( forecasts, feedback ) and ScenarioManager::HasCapacityForMaximumNumberofConcurrentRuns( ScenarioManager, SelectionScenario.Data(), true, feedback ); *] }