Exemple #1
0
 public PanelViewModel()
 {
     ResultListViewModel = new ResultListViewModel();
     FindCommand         = new ExtendedRelayCommand(OnFindCommand);
     InsertCommand       = new ExtendedRelayCommand(OnInsertCommand);
     CloseCommand        = new ExtendedRelayCommand(OnCloseCommand);
     InitializeData();
 }
        public InsertDialogViewModel(IEnumerable <KeyValuePair <int?, string> > types)
        {
            List <KeyValuePair <int?, string> > keyValuePairs = new List <KeyValuePair <int?, string> >(types);

            keyValuePairs.Insert(0, new KeyValuePair <int?, string>(null, "n/a"));
            CompanyTypes        = new ObservableCollection <KeyValuePair <int?, string> >(keyValuePairs);
            SelectedCompanyType = keyValuePairs.FirstOrDefault();

            ConfirmCommand    = new ExtendedRelayCommand(OnConfirmCommand);
            CancelCommand     = new ExtendedRelayCommand(OnCancelCommand);
            IsDialogConfirmed = false;
        }
 public TestViewModel()
 {
     Command = new ExtendedRelayCommand(OnCommand);
 }