springboot 处理put请求参数

阅读 76

2022-04-25

put请求参数理论上是在请求的body中(json传输),但是使用如下方式不能得到:

@RequestParam Integer meetingId,@RequestParam Boolean pass

但是如果直接将参数拼接在url后可以取到。

为了是参数在body中能被取到,我目前使用这种方式:

@RequestBody Map<String, Object> json

但是如果body中有map参数的话可能有错误,这个问题仍需研究。

参考资料

参考:https://segmentfault.com/q/1010000006665586

精彩评论(0)

0 0 举报