public ActionResult Edit(int id) { //int itemId = Request[""] QA.Model.MenuInfo menuItem = menuInfoService.LoadEntities(m => m.ID == id).FirstOrDefault(); return(View(menuItem)); }
public ActionResult Edit(QA.Model.MenuInfo menuInfo) { bool result = menuInfoService.EditEntity(menuInfo); if (result) { return(Content("ok")); } return(Content("failed to update a menu item")); }
public ActionResult AddMenu(QA.Model.MenuInfo menuInfo) { menuInfo.SubBy = this.LoginUserInfo.ID; menuInfo.SubTime = DateTime.Now; menuInfo.DelFlag = (short)QA.Model.Enum.DelFlagEnum.Normal; menuInfo.DialogHeight = 500; menuInfo.DialogWidth = 500; menuInfo.IsVisable = true; menuInfo.ParentId = 1; menuInfoService.AddEntity(menuInfo); return(Content("ok")); }