コード例 #1
0
 public ActionResult AddSystemValue(SystemValueCreateModel model)
 {
     if (ModelState.IsValid)
     {
         try
         {
             model.AddSystemValue();
             ShowSuccessMessage("System Value sucessfully added.");
             return RedirectToAction("Details", new { CategoryId = model.CategoryId });
         }
         catch (Exception ex)
         {
             ShowErrorMessage(ex.Message);
         }
     }
     return View(model);
 }
コード例 #2
0
 public ActionResult AddSystemValue(int CategoryId)
 {
     var model = new SystemValueCreateModel();
     model.CategoryId = CategoryId;
     return View(model);
 }