@ResponseBody 默认的不是UTF-8。
所以
应该这么来
@RequestMapping(value = "list", produces = "application/json; charset=utf-8")
@ResponseBody
public String queryall(String rows,String page,HttpServletResponse response) throws Exception
{
List<Map> list=cdService.query_page(page, rows);
int total = cdService.getTotal();
JSONObject data = new JSONObject();
data.put("total",total);
data.put("rows", list);
System.out.println(data.toString());
String json=data.toString().toString();
return json;
}
OK!
参考http://www.cnblogs.com/dyllove98/p/3180158.html