Spring @ModelAttribute Model field mapping

前端 未结 2 1431
感动是毒
感动是毒 2021-01-20 22:24

I am rewriting an old REST service written in an in-house framework to use Spring. I have a Controller with a POST method which takes a parameter either as a POST or as

2条回答
  •  不知归路
    2021-01-20 23:21

    I also met a similar case you, Please replace @ModelAttribute("some_property") with @RequestBody.

    Hope to help you!

提交回复
热议问题