前台分页: sidePagination: "client",对应的json格式必须为: [ { "id":1, "name":"张三", "age":22 }, ... ] 后台分页: sidePagination: "server",对应的json格式必须为: { "total":20, "rows":[ { "id":1, "name":"张三", "age":22 }, ... ] }
com.force.json.JSONObject json_total = new com.force.json.JSONObject(); json_total.Put("total",200); json_total.Put("rows", jarray); //在这里组建后台分页json格式 context.Response.Write(json_total.ToString()); context.Response.Flush();