标签:http io ar sp on as new tt res
@RequestMapping(value="getCountyBycityId")
public void getCountyBycityId(HttpServletRequest request,HttpServletResponse response) throws Exception{
Long cityId = Long.parseLong(request.getParameter("cityId"));
ObjectMapper mapper = new ObjectMapper();
List<CrmProvinceCity> list = creditContractService.getCountyBycityId(cityId);
String jsonString = mapper.writeValueAsString(list);
response.setContentType("text/json;charset=utf-8");
response.getWriter().print(jsonString);
}
标签:http io ar sp on as new tt res
原文地址:http://www.cnblogs.com/yy123/p/4128420.html