@PostMapping(name="获取用户信息", value="/getUser/{userId}")
public Object getUser(@PathVariable("userId") String userId) {
    try {
        User user = userService.getUser(userId);
        return user;
    } catch (Exception e) {
        logger.error("获取用户信息异常 " + e.getMessage());
        return "获取用户信息异常");
    }
}

 

posted on 2019-01-17 14:14  境艺  阅读(583)  评论(0)    收藏  举报