Exemplo n.º 1
0
        // GET: Carts
        public async Task <IActionResult> Index()
        {
            string userId = User.FindFirstValue(ClaimTypes.NameIdentifier);

            var cart = await _cartService.GetByUserId(userId);

            return(View(CartViewModel.ToViewModel(cart)));
        }