@RequestMapping(value = "", method = RequestMethod.POST) public Result get(@RequestBody User user, @RequestParam("username") String hehe) throws Exception {}如何能夠接受user對象的同時(shí),同時(shí)接受username?假設(shè)User對象為public class User { private String id; private String username; private String email; private String phone;}
Springmvc中@RequestBody和@RequestParam能夠同時(shí)使用嗎
繁華開滿天機(jī)
2019-03-23 19:14:55