package com.bizmatics.controller.web; import com.bizmatics.model.User; import com.bizmatics.service.UserService; import org.springframework.beans.factory.annotation.Autowired; import org.springframework.web.bind.annotation.PostMapping; import org.springframework.web.bind.annotation.RequestBody; import org.springframework.web.bind.annotation.RequestMapping; import org.springframework.web.bind.annotation.RestController; /** * * 用户 * @author ya * @since 2021-07-07 */ @RestController @RequestMapping("/user") public class UserController { @Autowired private UserService userService; @PostMapping("register") public void register(@RequestBody User user){ userService.register(user); } }