public async Task <ActionResult> SelectFlat(Guid PeriodId) { ViewBag.PeriodId = PeriodId; var flats = await buildingService.GetFlats(); return(View(flats)); }
public async Task <ActionResult> MyFlats() { var userID = await accountService.GetUserId(User.Identity.Name); var ownerid = await accountService.GetOwnerId(userID); if (ownerid == null) { return(RedirectToAction("Index", "Home")); } return(View(await buildingService.GetFlats(ownerid))); }
// GET: Flat public async Task <ActionResult> Index() { return(View(await buildingService.GetFlats())); }