/// <summary> /// 加载树结构分页数据 /// </summary> public ActionResult GetTreePaged(string id, int page, int rows, List <MyFilter> filters, string orders = "") { filters = filters == null ? new List <MyFilter>() : filters; var sql = "SELECT T.* FROM V_Auth_Authorization T "; if (!string.IsNullOrEmpty(id)) { sql += string.Format("WHERE T.ParentID='{0}'", id); var data = QueryService.GetData(sql, null, orders); return(Json_Get(data)); } sql += "WHERE (T.ParentID IS NULL OR T.ParentID='')"; var result = QueryService.CreateTreePagedSQLQuery(sql, page, rows, filters, orders); return(Json_Get(new { total = result.total, rows = result.rows })); }