Example #1
0
        public ApplicationModuleRelationViewModel()
        {
            SelectionChangedCommand = new DelegateCommand <object>(SelectionChanged);

            List <DynEntity> applications = ApplicationDesignService.GetAllApplicationCollection();

            ApplicationSource.Clear();
            foreach (var application in applications)
            {
                DesignApplication designApplication = new DesignApplication(application);
                ApplicationSource.Add(designApplication);
                SelectedApplication = ApplicationSource[0];
            }
            InitModules();
        }
Example #2
0
        public ApplicationManagerViewModel()
        {
            AddDesignApplicationCommand    = new DelegateCommand <object>(AddDesignApplication);
            EditDesignApplicationCommand   = new DelegateCommand <object>(EditDesignApplication, CanEditDesignApplicationExecute);
            DeleteDesignApplicationCommand = new DelegateCommand <object>(DeleteDesignApplication, CanDeleteDesignApplicationExecute);
            RowActivatedCommand            = new DelegateCommand <object>(RowActivate);

            CheckedCommand   = new DelegateCommand <object>(Checked);
            UncheckedCommand = new DelegateCommand <object>(UnChecked);

            _applicationSource = new ObservableCollection <DesignApplication>();

            List <DynEntity> applications = ApplicationDesignService.GetAllApplicationCollection();

            ApplicationSource.Clear();
            foreach (var application in applications)
            {
                DesignApplication applicationViewModel = new DesignApplication(application);
                ApplicationSource.Add(applicationViewModel);
            }
        }