public ActionResult EditByModule(string id, string moduleId) { ViewBag.RoleId = id; if (string.IsNullOrEmpty(moduleId)) { moduleId = "1"; } int moduleIdInt = Convert.ToInt32(moduleId); RoleManagerByTab manager = RoleManagerByTab.GetByRoleIdAndTabId(id, moduleIdInt); return(View(manager)); }
public ActionResult EditPeribadi(RoleManagerByTab manager, string Command) { if (manager.HtmlRolesWithTabs != null && !string.IsNullOrEmpty(Command)) { //convert tabId to int int tabIdint = Convert.ToInt32(Command); //save changes HtmlRole.EditList(manager.HtmlRolesWithTabs, tabIdint); } return(RedirectToAction("EditByModule", new { id = manager.RoleId, moduleId = manager.ModuleId })); }