Exemplo n.º 1
0
        private void UpdateCustomRuleConstraints()
        {
            var customRuleConstraintNames = _automationService.GetCustomRuleConstraintNames(Model.EventName).Select(x => new RuleConstraintName(x)).ToList();

            _ruleConstraintValues.Clear();
            _ruleConstraintValues.AddRange(Model.GetRuleConstraintValues()
                                           .Select(x => new RuleConstraintValueViewModel(x, customRuleConstraintNames, RemoveConstraintCommand)));
            RaisePropertyChanged(() => RuleConstraintValues);
            RaisePropertyChanged(() => IsConstraintsVisible);
        }
Exemplo n.º 2
0
        private void UpdateCustomRuleConstraints()
        {
            if (string.IsNullOrEmpty(Model.EventName))
            {
                return;
            }
            var customRuleConstraintNames = _automationService.GetCustomRuleConstraintNames(Model.EventName).Select(x => new RuleConstraintName(x)).ToList();

            _ruleConstraintValues.Clear();
            _ruleConstraintValues.AddRange(Model.GetRuleConstraintValues()
                                           .Select(x => new RuleConstraintValueViewModel(x, customRuleConstraintNames, RemoveConstraintCommand)));
            RaisePropertyChanged(nameof(RuleConstraintValues));
            RaisePropertyChanged(nameof(IsConstraintsVisible));
        }