Ejemplo n.º 1
0
        public ActionResult AddToCart(int id)
        {
            ShoppingCartActions shopping = new ShoppingCartActions();
            orderline           or       = new orderline {
                idProduct_fk = id, qte = 1
            };

            shopping.addToCart(or);
            foreach (var item in shopping.getCurrentSessionOrderLines())
            {
                System.Diagnostics.Debug.WriteLine(" order lines" + item.idProduct_fk + "  " + item.qte);
            }
            return(RedirectToAction("Index"));
        }