Example #1
0
 public ActionResult DeleteProduct(Guid id)
 {
     try
     {
         var res = ApiUtil.DeleteProduct(id);
         return(RedirectToAction("ListProduct"));
     }
     catch (Exception ex)
     {
         return(RedirectToAction("Index", new RouteValueDictionary(new { controller = "ErrorHandler", action = "Index", data = ex.InnerException?.Message ?? ex.Message })));
     }
 }