Browse Source

人员配置选人修改

wangliang 10 months ago
parent
commit
cc87675e2a

+ 11 - 2
sop-business/src/main/java/com/qmth/sop/business/service/impl/TBUserArchivesAllocationServiceImpl.java

@@ -597,8 +597,17 @@ public class TBUserArchivesAllocationServiceImpl
             switch (sopRoleTypeCompositeEnum) {
             case ENGINEER:
             case PROJECT_MANAGER:
-                datasource = tbUserArchivesService.list().stream().map(TBUserArchives::getId).distinct()
-                        .collect(Collectors.toList());
+                switch (productTypeEnum) {
+                case OFFICE:
+                    datasource = tbUserArchivesService.list().stream().map(TBUserArchives::getId).distinct()
+                            .collect(Collectors.toList());
+                    break;
+                case CLOUD_MARK:
+                    datasource = tbUserArchivesService.findArchivesSourceByType(
+                                    new HashSet<>(Arrays.asList(RoleTypeEnum.EFFECT_ENGINEER, RoleTypeEnum.ASSISTANT_ENGINEER)))
+                            .stream().map(ArchivesSourceResult::getArchivesId).distinct().collect(Collectors.toList());
+                    break;
+                }
                 break;
             case REGION_COORDINATOR:
                 datasource = tbUserArchivesService.findArchivesSourceByType(