// GET: Region public ActionResult Index() { var userId = Guid.Parse(User.Identity.GetUserId()); var service = new RegionService(userId); var model = service.GetAllRegions(); return(View(model)); }
public ActionResult Index() { var beers = BeerService.GetPopularBeers().Distinct().ToList(); ViewBag.Count = beers.Count(); ViewBag.Beers = beers; var regions = RegionService.GetAllRegions(); var dict = regions.ToDictionary(region => region.Id, region => region.Name); ViewBag.SelectList = new SelectList(dict, "Key", "Value"); var model = new UserModel(); return(View(model)); }
public async Task <List <RegionDto> > GetRegion() { return(await regionService.GetAllRegions()); }
public List <RegionModel> Get() { return(RegionService.GetAllRegions(dbConn)); }