Example #1
0
        public async Task <IActionResult> Index()
        {
            var items = await _Cart.GetCartItemAsync();

            _Cart.cart = items;

            var ItemModel = new ItemViewModel
            {
                Cart      = _Cart,
                CartTotal = _Cart.GetCartTotal()
            };

            return(View(ItemModel));
        }