Exemplo n.º 1
0
        public ActionResult GetAllUsersWishListsOfGift(int giftId)
        {
            var userId          = CurrentUser.Id;
            var wishListsOfGift = _wishListService.GetAllUsersWishListsOfGift(giftId, userId).ToList();

            if (wishListsOfGift.Count < 1)
            {
                return(new EmptyResult());
            }

            var model = Mapper.Map <IEnumerable <UsersWishListsOfGiftViewModel> >(wishListsOfGift);

            model.ForEach(x => x.GiftId = giftId);

            return(PartialView("_GetAllUsersWishListsOfGift", model));
        }