public async Task <IActionResult> Details(Guid id, CancellationToken token = default) { if (await _accountRepository.GetAsync(id, token) is Account account) { var model = new WishlistEditModel { AccountId = account.Id, DisplayName = account.DisplayName }; if (account.Wishlist.ContainsKey(DateHelper.Year)) { model.Items = account.Wishlist[DateHelper.Year]; } return(View(model)); } return(RedirectToAction("Index", "Home")); }
// // GET: /Wishlist/Details public IActionResult Details(Guid id) { var model = new WishlistEditModel(id); return(View(model)); }
// // GET: /Wishlist/ public IActionResult Index() { var model = new WishlistEditModel(User.GetAccount().Id.Value); return(View(model)); }