예제 #1
0
        public WallViewModel(
            IDataService <Requirement> requirementDataService,
            IActionConfirmationService actionConfirmation)
            : base(requirementDataService, actionConfirmation)
        {
            Prioritised = new SwimlaneViewModel(requirementDataService, RequirementStatus.Prioritised);
            WIP         = new SwimlaneViewModel(requirementDataService, RequirementStatus.WIP);
            Test        = new SwimlaneViewModel(requirementDataService, RequirementStatus.Test);
            Done        = new SwimlaneViewModel(requirementDataService, RequirementStatus.Done);

            PollingService.Instance.IntervalElapsed += OnPollingIntervalElapsed;
            MessengerInstance.Register <ReloadRequestMessage>(this, OnReloadRequest);
        }
예제 #2
0
        public DataBoundViewModel(
            IDataService <T> dataService,
            IActionConfirmationService actionConfirmation)
        {
            DataService        = dataService;
            ActionConfirmation = actionConfirmation;

            Index = new ObservableCollection <T>();

            NewCmd    = new RelayCommand(OnNew, () => CanExecuteNew);
            EditCmd   = new RelayCommand(OnEdit, () => CanExecuteEdit);
            DeleteCmd = new RelayCommand(OnDelete, () => CanExecuteSelectedItemChange);
            SaveCmd   = new RelayCommand(OnSave, () => CanExecuteSave);
            CancelCmd = new RelayCommand(OnCancel, () => CanExecuteCancel);
        }
예제 #3
0
        public RequirementViewModel(
            IDataService <Requirement> requirementDataService,
            IDataService <Lookup> lookupService,
            IActionConfirmationService actionConfirmation)
            : base(requirementDataService, actionConfirmation)
        {
            _storyFilter = string.Empty;

            _lookupDataService = lookupService;

            _excelAdapter   = new IndexExcelAdapter <Requirement>();
            IndexToExcelCmd = new RelayCommand(OnIndexToExcel, () => _excelAdapter.CanExecute);
            ExcelToIndexCmd = new RelayCommand(OnExcelToIndex, () => _excelAdapter.CanExecute);

            ClearRequirementStatusCmd = new RelayCommand(
                OnClearRequirementStatus, () => CanExecute);

            MessengerInstance.Register <StoryFilterMessage>(this, OnFindStory);
        }