소스 검색

部门用户判断

liangpeile 1 년 전
부모
커밋
6ae4dab4cd
1개의 변경된 파일3개의 추가작업 그리고 1개의 파일을 삭제
  1. 3 1
      crmeb-service/src/main/java/com/zbkj/service/service/impl/OrganizationDepartmentServiceImpl.java

+ 3 - 1
crmeb-service/src/main/java/com/zbkj/service/service/impl/OrganizationDepartmentServiceImpl.java

@@ -90,7 +90,9 @@ public class OrganizationDepartmentServiceImpl extends ServiceImpl<OrganizationD
 
         LambdaQueryWrapper<OrganizationDepartmentUser> queryWrapper1 = new LambdaQueryWrapper<>();
         queryWrapper1.eq(OrganizationDepartmentUser::getOrganizationId, organizationId);
-        queryWrapper1.in(OrganizationDepartmentUser::getDepartmentId, split);
+        if (StringUtils.isNotBlank(departmentId)){
+            queryWrapper1.in(OrganizationDepartmentUser::getDepartmentId, split);
+        }
         List<OrganizationDepartmentUser> list = organizationDepartmentUserService.list(queryWrapper1);
         List<String> ids = list.stream().map(OrganizationDepartmentUser::getDepartmentId).collect(Collectors.toList());