@RequestMapping(value = "hello", method = {RequestMethod.POST})
@ResponseBody
public boolean hello(@RequestParam(value = "userIds") List<Long> userIds) {
return false;
}
针对于这种 前端如何传递参数?
POST http://localhost:8081/hello Content-Type: application/x-www-form-urlencoded userIds=[12976923,1111]
如果这样传参 后端接收的是
那前端如何传递参数?
POST http://localhost:8081/hello Content-Type: application/x-www-form-urlencoded userIds=12976923,1111
如果这样传参 后端接收的是