From 5dc4b1e4827c4dfe863422f6877ccafee43518dc Mon Sep 17 00:00:00 2001 From: wangliwen Date: Wed, 14 Dec 2022 11:32:34 +0800 Subject: [PATCH] =?UTF-8?q?=E5=88=86=E9=A1=B5=E6=95=B0=E9=87=8F=E4=B8=8D?= =?UTF-8?q?=E6=AD=A3=E7=A1=AE?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../sys/controller/SysUserController.java | 2 +- .../io/renren/modules/sys/dao/SysUserDao.java | 2 +- .../modules/sys/service/SysUserService.java | 2 +- .../sys/service/impl/SysUserServiceImpl.java | 4 +- .../main/resources/mapper/sys/SysUserDao.xml | 43 ++++++++++++++++++- 5 files changed, 46 insertions(+), 7 deletions(-) diff --git a/renren-admin/src/main/java/io/renren/modules/sys/controller/SysUserController.java b/renren-admin/src/main/java/io/renren/modules/sys/controller/SysUserController.java index 1f62f822..5954aa42 100644 --- a/renren-admin/src/main/java/io/renren/modules/sys/controller/SysUserController.java +++ b/renren-admin/src/main/java/io/renren/modules/sys/controller/SysUserController.java @@ -285,6 +285,6 @@ public class SysUserController { index.put("auditTeamName", sysAuditTeamDTOList.stream().findFirst().isPresent() ? sysAuditTeamDTOList.stream().findFirst().get().getName() : ""); return index; }).collect(Collectors.toList()); - return new Result>().ok(new PageData<>(temp, sysUserService.getUserByRoleListCount(roleId))); + return new Result>().ok(new PageData<>(temp, sysUserService.getUserByRoleListCount(roleId, filterAuditTeam))); } } \ No newline at end of file diff --git a/renren-admin/src/main/java/io/renren/modules/sys/dao/SysUserDao.java b/renren-admin/src/main/java/io/renren/modules/sys/dao/SysUserDao.java index 509cb494..a3bbdf95 100644 --- a/renren-admin/src/main/java/io/renren/modules/sys/dao/SysUserDao.java +++ b/renren-admin/src/main/java/io/renren/modules/sys/dao/SysUserDao.java @@ -59,5 +59,5 @@ public interface SysUserDao extends BaseDao { List getUserByRoleList(@Param("roleIds") List roleIds, @Param("pageNum") int pageNum, @Param("pageSize") int pageSize, @Param("filter") boolean filter); - Long getUserByRoleListCount(@Param("roleIds") List roleIds); + Long getUserByRoleListCount(@Param("roleIds") List roleIds, @Param("filter") boolean filter); } \ No newline at end of file diff --git a/renren-admin/src/main/java/io/renren/modules/sys/service/SysUserService.java b/renren-admin/src/main/java/io/renren/modules/sys/service/SysUserService.java index 9dd3157d..a5e438f1 100644 --- a/renren-admin/src/main/java/io/renren/modules/sys/service/SysUserService.java +++ b/renren-admin/src/main/java/io/renren/modules/sys/service/SysUserService.java @@ -74,5 +74,5 @@ public interface SysUserService extends BaseService { */ List getUserByRoleList(List roleIds, int pageNum, int pageSize, boolean filter); - Long getUserByRoleListCount(List roleIds); + Long getUserByRoleListCount(List roleIds, boolean filter); } diff --git a/renren-admin/src/main/java/io/renren/modules/sys/service/impl/SysUserServiceImpl.java b/renren-admin/src/main/java/io/renren/modules/sys/service/impl/SysUserServiceImpl.java index cb85aff6..ef93af9a 100644 --- a/renren-admin/src/main/java/io/renren/modules/sys/service/impl/SysUserServiceImpl.java +++ b/renren-admin/src/main/java/io/renren/modules/sys/service/impl/SysUserServiceImpl.java @@ -568,7 +568,7 @@ public class SysUserServiceImpl extends BaseServiceImpl roleIds) { - return baseDao.getUserByRoleListCount(roleIds); + public Long getUserByRoleListCount(List roleIds, boolean filter) { + return baseDao.getUserByRoleListCount(roleIds, filter); } } diff --git a/renren-admin/src/main/resources/mapper/sys/SysUserDao.xml b/renren-admin/src/main/resources/mapper/sys/SysUserDao.xml index 808bcc08..cdf6dbdf 100644 --- a/renren-admin/src/main/resources/mapper/sys/SysUserDao.xml +++ b/renren-admin/src/main/resources/mapper/sys/SysUserDao.xml @@ -261,8 +261,32 @@ LIMIT ${pageNum}, ${pageSize}