예제 #1
0
 public ActionResult Create(PathNode pathNode)
 {
     string strResult = string.Empty;
     bool bResult = PathNodeService.Add(pathNode);
     string msg = bResult ? "新增成功" : "新增失败";
     return Json(JsonMessageHelper.getJsonMessage(bResult, msg, null), "text", JsonRequestBehavior.AllowGet);
 }
예제 #2
0
 public ActionResult Delete(PathNode pathNode)
 {
     string strResult = string.Empty;
     bool bResult = false;
     bResult = PathNodeService.Delete(pathNode);
     string msg = bResult ? "删除成功" : "删除失败";
     return Json(JsonMessageHelper.getJsonMessage(bResult, msg, strResult), "text", JsonRequestBehavior.AllowGet);
 }
예제 #3
0
 //
 // GET: /PathNode/Details/
 public ActionResult Details(int page, int rows, FormCollection collection)
 {
     PathNode pathNode = new PathNode();
     //string ID = collection["ID"] ?? "";
     //string PathName = collection["PathName"] ?? "";
     //string PositionName = collection["PositionName"] ?? "";
     //string PathNodeOrder = collection["PathNodeOrder"] ?? "";
     string PathID = collection["PathID"] ?? "";
     if (PathID != null && PathID != "")
     {
         pathNode.PathID = Convert.ToInt32(PathID);
     }
     if (PathID != null && PathID != "")
     {
         pathNode.PathID = Convert.ToInt32(PathID);
     }
     var srm = PathNodeService.GetDetails(page, rows, pathNode);
     return Json(srm, "text", JsonRequestBehavior.AllowGet);
 }
예제 #4
0
 //
 // POST: /PathNode/Edit
 public ActionResult Edit(PathNode pathNode)
 {
     string strResult = string.Empty;
     bool bResult = PathNodeService.Save(pathNode);
     string msg = bResult ? "修改成功" : "修改失败";
     return Json(JsonMessageHelper.getJsonMessage(bResult, msg, strResult), "text", JsonRequestBehavior.AllowGet);
 }
예제 #5
0
 public ActionResult PathEdit(string pathID, string PositionID, string PathNodeOrder)
 {
     PathNode pathNode = new PathNode();
     pathNode.ID = Convert.ToInt32(pathID);
     pathNode.PositionID = Convert.ToInt32(PositionID);
     pathNode.PathNodeOrder = Convert.ToInt32(PathNodeOrder);
     bool bResult = PathNodeService.Save(pathNode);
     string msg = bResult ? "修改成功" : "修改失败";
     return Json(JsonMessageHelper.getJsonMessage(bResult, msg, null), "text", JsonRequestBehavior.AllowGet);
 }