| | |
| | | @ApiOperationSupport(order = 1) |
| | | @ApiOperation(value = "查看详情", notes = "传入id") |
| | | @GetMapping("/detail") |
| | | @PreAuth(RoleConstant.HAS_ROLE_ADMIN) |
| | | @PreAuth("hasAnyRole('administrator,admin,user')") |
| | | public R<UserVO> detail(User user) { |
| | | User detail = userService.getOne(Condition.getQueryWrapper(user)); |
| | | return R.data(UserWrapper.build().entityVO(detail)); |
| | |
| | | @ApiOperationSupport(order = 5) |
| | | @ApiOperation(value = "修改", notes = "传入User") |
| | | public R update(@Valid @RequestBody User user) { |
| | | CacheUtil.clear(USER_CACHE); |
| | | // CacheUtil.clear(USER_CACHE); |
| | | return R.status(userService.updateUser(user)); |
| | | } |
| | | |