@RequestMapping(value = "/map")
public @ResponseBody Map<String, Object> mapRequest() {
Map<String, Object> map = new HashMap<String, Object>();
map.put("code", 200);
map.put("message", "success");
return map;
}
Spring Boot 返回json
原创深漂小码哥 ©著作权
文章标签 java spring spring boot mysql 文章分类 spring boot 后端开发