private bool CanExecuteAutomationCommand(AutomationCommandData arg) { if (arg == null) { return(false); } if (_paymentEditor.SelectedTicket != null && _paymentEditor.SelectedTicket.IsLocked && arg.VisualBehaviour == 1) { return(false); } if (!arg.CanExecute(_paymentEditor.SelectedTicket)) { return(false); } return(_expressionService.EvalCommand(FunctionNames.CanExecuteAutomationCommand, arg.AutomationCommand, new { Ticket = _paymentEditor.SelectedTicket }, true)); }
private bool CanSelectAutomationCommand(AutomationCommandData arg) { return(arg.CanExecute(SelectedTicket) && _expressionService.EvalCommand(FunctionNames.CanExecuteAutomationCommand, arg.AutomationCommand, new { Ticket = SelectedTicket }, true)); }