|
@@ -215,12 +215,14 @@ public class AdminUserLogic {
|
|
|
.map(AdminUserPermissions::getAdminUserPermissionsId)
|
|
|
.collect(Collectors.toList());
|
|
|
|
|
|
- final List<AdminDept> deptExistList = adminDeptService.lambdaQuery()
|
|
|
- .in(AdminDept::getAdminDeptId, deptList)
|
|
|
- .list();
|
|
|
+ if (CollectionUtil.isNotEmpty(deptList)) {
|
|
|
+ final List<AdminDept> deptExistList = adminDeptService.lambdaQuery()
|
|
|
+ .in(AdminDept::getAdminDeptId, deptList)
|
|
|
+ .list();
|
|
|
|
|
|
- if (deptExistList.size() < deptList.size()) {
|
|
|
- throw new RemoteServiceException("选择里有异常部门");
|
|
|
+ if (deptExistList.size() < deptList.size()) {
|
|
|
+ throw new RemoteServiceException("选择里有异常部门");
|
|
|
+ }
|
|
|
}
|
|
|
|
|
|
final List<String> websitList = permissions.stream()
|
|
@@ -228,12 +230,14 @@ public class AdminUserLogic {
|
|
|
.map(AdminUserPermissions::getAdminUserPermissionsId)
|
|
|
.collect(Collectors.toList());
|
|
|
|
|
|
- final List<AdminWebsit> websitExistList = adminWebsitService.lambdaQuery()
|
|
|
- .in(AdminWebsit::getWebsitId, websitList)
|
|
|
- .list();
|
|
|
+ if (CollectionUtil.isNotEmpty(websitList)) {
|
|
|
+ final List<AdminWebsit> websitExistList = adminWebsitService.lambdaQuery()
|
|
|
+ .in(AdminWebsit::getWebsitId, websitList)
|
|
|
+ .list();
|
|
|
|
|
|
- if (websitExistList.size() < websitList.size()) {
|
|
|
- throw new RemoteServiceException("选择里有异常商家");
|
|
|
+ if (websitExistList.size() < websitList.size()) {
|
|
|
+ throw new RemoteServiceException("选择里有异常商家");
|
|
|
+ }
|
|
|
}
|
|
|
|
|
|
// 清空权限关系
|