Quellcode durchsuchen

加入历史项目经理审批

wangliang vor 1 Jahr
Ursprung
Commit
6a758ee8e8

+ 5 - 2
sop-business/src/main/java/com/qmth/sop/business/service/impl/TBSopInfoServiceImpl.java

@@ -1278,8 +1278,7 @@ public class TBSopInfoServiceImpl extends ServiceImpl<TBSopInfoMapper, TBSopInfo
                 tbSopLogService.save(tbSopLog);
             }
 
-            if (tfCustomFlow.getType() == TFCustomTypeEnum.OFFICE_SOP_FLOW
-                    && scopeEnum != scopeOldEnum) {//教务处sop流程待审核人
+            if (tfCustomFlow.getType() == TFCustomTypeEnum.OFFICE_SOP_FLOW && scopeEnum != scopeOldEnum) {//教务处sop流程待审核人
                 List<AllocationParam> allocationParams = new ArrayList<>();
                 Task task = taskService.createTaskQuery().processInstanceId(tfCustomFlowEntity.getFlowId().toString())
                         .singleResult();
@@ -1304,6 +1303,10 @@ public class TBSopInfoServiceImpl extends ServiceImpl<TBSopInfoMapper, TBSopInfo
                     tbSopInfoService.sopApproverExchange(tbCrmDetail.getId(), new SopAllocationParam(
                             new UserArchivesAllocationParam(allocationParams, tbCrmDetail.getId())));
                     allocationParams.add(new AllocationParam(SopRoleTypeEnum.ENGINEER, enginessUserIds, "[系统]"));
+                    if (!CollectionUtils.isEmpty(crmProjectResult.getRegionCoordinatorList())) {
+                        allocationParams.add(new AllocationParam(SopRoleTypeEnum.REGION_COORDINATOR,
+                                Arrays.asList(crmProjectResult.getRegionCoordinatorList().get(0).getUserId()), "[系统]"));
+                    }
                     tbUserArchivesAllocationService.editCrmAllocation(
                             new UserArchivesAllocationParam(allocationParams, tbCrmDetail.getId()));
                 }

+ 1 - 1
sop-business/src/main/resources/mapper/TBSopInfoMapper.xml

@@ -64,7 +64,7 @@
                tfcf.version,
                cast(tfcf.flow_deployment_id as char) as flowDeploymentId,
                art.TASK_DEF_KEY_ as taskDefKey,
-               tbcd.id as crmDetailId,
+               cast(tbcd.id as char) as crmDetailId,
                if((select count(1) from t_b_ding tbd where tbd.sop_no = tbsi.sop_no and tbd.ding_exception = 1) > 0,true,false) as dingException,
                (select group_concat(cast(art.ID_ as char)) from ACT_RU_TASK art where art.PROC_INST_ID_ = tffa.flow_id) as taskId
                 <if test="fieldName != null and fieldName != ''">