Ejemplo n.º 1
0
        public ActionResult Index(string SearchActionName, string SearchControllerName, string SearchModule)
        {
            var moduleActionModel = new ModuleActionModel();
            var moduleActionList  = moduleActionModel.GetListOfModuleActions(true, false, SearchActionName, SearchControllerName, SearchModule);

            return(View(moduleActionList));
        }
Ejemplo n.º 2
0
        public ActionResult GetActionsForController(string controllerId)
        {
            if (String.IsNullOrEmpty(controllerId))
            {
                throw new ArgumentNullException("countryId");
            }

            var moduleActionModel = new ModuleActionModel();
            var actionList        = moduleActionModel.GetListOfModuleActions(false, false);

            actionList.RemoveAll(x => x.Module_Controller_Id != int.Parse(controllerId));

            var result = (from a in actionList
                          select new
            {
                id = a.Module_Action_Id,
                name = a.Module_Action_Name
            }).ToList();

            return(Json(result, JsonRequestBehavior.AllowGet));
        }