public ActionResult AddTOCart(int productId) { var userId = Current.User.Identity.GetUserId(); service.AddTOCart(userId, productId); return(View("Index", CartServices.GetAllProducts())); }
// GET: ShopNow public ActionResult Index() { var userId = Current.User.Identity.GetUserId(); var product = CartServices.GetAllProducts(); service.OpenCart(userId); return(View(product)); }