Example #1
0
        public ActionResult _ShoppingCartModal()
        {
            var model = new ShoppingCartModalViewModel()
            {
                CartItems = _cartService.GetCartWithAssociatedProducts(_shoppingCartID)
            };

            return(PartialView(model));
        }
Example #2
0
        public ActionResult _ShoppingCartModal()
        {
            IEnumerable <CartItem> cartItems =
                _shoppingCartService.GetCartWithProducts(Utility.Helpers.ShoppingCartHelpers.GetShoppingCartId(this.ControllerContext));

            ShoppingCartModalViewModel model = new ShoppingCartModalViewModel()
            {
                CartItems = cartItems
            };

            return(PartialView("~/Views/Shared/_ShoppingCartModal.cshtml", model));
        }