第1个回答 2017-10-27
可以通过@RequestBody注解来实现
import org.springframework.web.bind.annotation.RequestBody;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.ResponseBody;
@RequestMapping("/")
@ResponseBody
public JsonDto someFunction(@RequestBody Dto dto) {
return null;
}