public IEnumerable <NoteCategoryViewModel> FetchNoteCategories() { var docs = _noteCategoriesRepository.Fetch(); if (docs.IsNullOrEmpty()) { return(null); } return(docs.Select(doc => JsonConvert.DeserializeObject <NoteCategoryViewModel>(doc.Content))); }
public IEnumerable <RecruitViewModel> FetchYearRecruits() { var docs = _yearRecruitsRepository.Fetch(); if (docs.IsNullOrEmpty()) { return(null); } return(docs.Select(doc => JsonConvert.DeserializeObject <RecruitViewModel>(doc.Content))); }