//
        // GET: /Matcher/
        public ActionResult Index()
        {
            MatcherVM mvm = new MatcherVM();

            mvm.Teams = _teamBLL.TeamMatcherList();

            return(View());
        }
示例#2
0
        public GeneralMatcherVM(Action <GeneralMatcherVM> removeFromUI, Action <GeneralMatcherVM> cleanupSetLevel)
        {
            AllMatcherTypes     = Enum.GetValues(typeof(MatcherType)).Cast <MatcherType>();
            SelectedMatcherType = MatcherType.Text;

            RemoveMatcher = new DelegateCommand(_ =>
            {
                MatcherVM.remove();
                removeFromUI(this);
            });

            this.cleanupSetLevel = cleanupSetLevel;
        }
示例#3
0
        public void propagateToBackingMatchers(MatcherChain matcherChain)
        {
            if (matcherVMRemoved != null)
            {
                matcherVMRemoved.propagateToBackingMatchers(matcherChain.Matchers, this);
                matcherVMRemoved = null;
            }
            MatcherVM.propagateToBackingMatchers(matcherChain.Matchers, this);
            if (MatcherVM.hasBackingMatcher())
            {
                MatcherVM.getBackingMatcher().Name = Name;
            }

            if (IsLevel && MatcherVM.hasBackingMatcher())
            {
                matcherChain.LevelMatcherRef = MatcherVM.getBackingMatcher();
            }
        }
示例#4
0
        private void OnSelectedMatcherChanged(MatcherType newValue)
        {
            if (MatcherVM != null)
            {
                MatcherVM.remove();
                if (MatcherVM.hasBackingMatcher())
                {
                    matcherVMRemoved = MatcherVM;
                }
            }
            MatcherVM    = getInstance(newValue);
            HasAffixes   = MatcherVM.hasAffixes();
            HasSeparator = MatcherVM.hasSeparator();

            CanBeLevel = canBeLevel(newValue);
            if (!CanBeLevel)
            {
                IsLevel = false;
            }
        }