public JsonResult OrgInfoList(FormCollection form) { string parentCode = form["parentCode"]; string colkey = form["colkey"]; string colsinfo = form["colsinfo"]; if (string.IsNullOrEmpty(colkey)) { throw new ArgumentNullException("colkey", "主键表示没有传递,请在前台js中配置"); } if (string.IsNullOrEmpty(colsinfo)) { throw new ArgumentNullException("colsinfo", "列信息不能为空,请在前台js中配置"); } if (string.IsNullOrEmpty(parentCode) || parentCode == "-1") { Organization root = sysManageService.GetRootOrganization(); parentCode = root.OrgCode; } List <Organization> list = sysManageService.GetChildOrgsByParentCode(parentCode); var data = JsonFlexiGridData.ConvertFromList(list, colkey, colsinfo.Split(',')); return(Json(data)); }