Beispiel #1
0
        public ActionResult CreateProduct(Product product)
        {
            products.Insert(product);
            products.Commit();

            return RedirectToAction("ProductList");
        }
Beispiel #2
0
        public ActionResult CreateProduct()
        {
            var model = new Product();

            return View(model);
        }
Beispiel #3
0
        public ActionResult EditProduct(Product product)
        {
            products.Update(product);
            products.Commit();

            return RedirectToAction("ProductList");
        }