mirror of
https://github.com/FatttSnake/Pinnacle-OA.git
synced 2026-04-06 07:21:24 +08:00
Added getNoticeUser
This commit is contained in:
@@ -55,6 +55,13 @@ public class UserController {
|
||||
return ResponseResult.databaseSaveSuccess(userService.getDepartmentUser());
|
||||
}
|
||||
|
||||
@GetMapping("/notice")
|
||||
@PreAuthorize("hasAuthority('notice:manage:get')")
|
||||
@Operation(summary = "获取拥有发布公告权限的用户")
|
||||
public ResponseResult<List<User>> getNoticeUser() {
|
||||
return ResponseResult.databaseSaveSuccess(userService.getNoticeUser());
|
||||
}
|
||||
|
||||
@GetMapping
|
||||
@PreAuthorize("hasAuthority('system:user:get')")
|
||||
@Operation(summary = "获取所有用户(权限管理相关)")
|
||||
|
||||
@@ -25,6 +25,8 @@ public interface UserMapper extends BaseMapper<User> {
|
||||
|
||||
List<User> getAllDepartmentUser(@Param("departmentId")long departmentId);
|
||||
|
||||
List<User> getAllNoticeUser();
|
||||
|
||||
User getOneById(@Param("id") long id);
|
||||
|
||||
User getOneWithPowerByUsername(@Param("username") String username);
|
||||
|
||||
@@ -22,6 +22,8 @@ public interface IUserService extends IService<User> {
|
||||
|
||||
List<User> getDepartmentUser();
|
||||
|
||||
List<User> getNoticeUser();
|
||||
|
||||
IPage<User> getAllUser(Long currentPage, Long pageSize, String searchName, List<Long> searchRole, List<Long> searchGroup, Integer searchEnable);
|
||||
|
||||
User getUser(long id);
|
||||
|
||||
@@ -89,6 +89,12 @@ public class UserServiceImpl extends ServiceImpl<UserMapper, User> implements IU
|
||||
return userMapper.getAllDepartmentUser(departmentId);
|
||||
}
|
||||
|
||||
@Override
|
||||
public List<User> getNoticeUser() {
|
||||
return userMapper.getAllNoticeUser();
|
||||
}
|
||||
|
||||
|
||||
@Override
|
||||
public IPage<User> getAllUser(Long currentPage, Long pageSize, String searchName, List<Long> searchRole, List<Long> searchGroup, Integer searchEnable) {
|
||||
IPage<User> userIPage = PageDTO.of(currentPage, pageSize);
|
||||
|
||||
Reference in New Issue
Block a user