//public ActionResult GetNotification(int Limit, int Offset) //{ // try // { // var ret = Navigation.GetNotification(Session["IDUser"].ToString(), Limit, Offset); // var resutltJson = from d in ret // select new string[] // { // d.IDNotification, // d.NotificationMessage, // d.NotificationStatus, // d.NotificationType, // d.UnreadMsg.ToString(), // d.DateOfNotification.ToString() // }; // return Json(ret, JsonRequestBehavior.AllowGet); // } // catch (Exception err) // { // var ret = "Err|" + err.Message; // return Json(ret, JsonRequestBehavior.AllowGet); // } //} //public ActionResult GetGauge() //{ // try // { // var ret = Dashboard.GetDashboard(Session["IDRole"].ToString()); // return Json(ret, JsonRequestBehavior.AllowGet); // } // catch (Exception err) // { // var ret = "Err|" + err.Message; // return Json(ret, JsonRequestBehavior.AllowGet); // } //} public JsonResult GenerateModule() { try { GenerateMenuModel mdl = new GenerateMenuModel(); mdl.IDSite = Session["IDsite"].ToString(); mdl.IDRole = Session["IDRole"].ToString(); mdl.IDLanguage = Session["CurrentUICulture"].ToString(); var NavigationMenu = new NavigationMenuClass(); var ret = NavigationMenu.GenerateModule(mdl); return(Json(ret, JsonRequestBehavior.AllowGet)); } catch (Exception err) { var ret = "Err|" + err.Message; return(Json(ret, JsonRequestBehavior.AllowGet)); } }
public List <PModuleFeatureToMenuTree_Result> GenerateModule(GenerateMenuModel GenerateMenu) { var res = db.PModuleFeatureToMenuTree(GenerateMenu.IDRole, GenerateMenu.IDSite, GenerateMenu.IDLanguage).ToList(); return(res); }