public IActionResult Get() { if (repo.GetAll().Any()) { return(Ok(repo.GetAll())); } else { return(NotFound()); } }
public ListResultOutput <CountryDto> GetCountries() { return(new ListResultOutput <CountryDto>(Mapper.Map <List <CountryDto> >(_countryRepository.GetAll()))); }
public async Task <IEnumerable <County> > GetCounties() { return(await _countyRepository.GetAll()); }
public IEnumerable <County> GetAll() { return(_countyRepository.GetAll()); }
public List <CountyViewModel> GetAll(bool inactive = false) { return(_countyRepository.GetAll(inactive).ToList() .Select(county => new CountyViewModel(county)) as List <CountyViewModel>); }
public IEnumerable <County> GetCounties() { return(_countyRepository.GetAll().ToList()); }
public Dictionary <Guid, string> Counties() { return(_countyRepository.GetAll().OrderBy(n => n.Name) .Select(r => new { r.Id, r.Name }).ToList().ToDictionary(d => d.Id, d => d.Name)); }