示例#1
0
 public BookViewModel(IContactDataService dataService,
                      IDialogService dialogService)
 {
     ContactsVM           = new ContactsViewModel(dataService, dialogService);
     _dataService         = dataService;
     LoadContactsCommand  = new RelayCommand(LoadContacts);
     LoadFavoritesCommand = new RelayCommand(LoadFavorites);
 }
示例#2
0
        public BookViewModel(IContactDataService service)
        {
            _service   = service;
            ContactsVM = new ContactsViewModel();

            LoadContactsCommand  = new RelayCommand(LoadContacts);
            LoadFavoritesCommand = new RelayCommand(LoadFavorites);
        }