diff --git a/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/feishu/enums/TemplateInfoEnum2.java b/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/feishu/enums/TemplateInfoEnum2.java index b4435659f..08698b578 100644 --- a/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/feishu/enums/TemplateInfoEnum2.java +++ b/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/feishu/enums/TemplateInfoEnum2.java @@ -87,6 +87,11 @@ public enum TemplateInfoEnum2 { */ REGULATION_OPINION_COLLECTION("法规意见收集","ctp_AArfYGLozU47","Regulation Opinion Collection"), + /** + * 法规技术评估 + */ + REGULATION_TECHNICAL_ASSESSMENT("法规技术评估","ctp_AArfYGLozU47","Regulation Technical Assessment"), + ; diff --git a/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/feishu/service/IFeishuService.java b/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/feishu/service/IFeishuService.java index f399bea99..59dec80b4 100644 --- a/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/feishu/service/IFeishuService.java +++ b/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/feishu/service/IFeishuService.java @@ -146,7 +146,7 @@ public interface IFeishuService { void sendMessageLawsWarn(String templeteId,Map params); /** - * 飞书消息模板--法规意见收集 + * 飞书消息模板--法规意见收集和法规技术评估 * @param templeteId * @param params */ diff --git a/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/lawsTechnologyEvaluation/job/LawsTechnologyEvaluationRemindJob.java b/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/lawsTechnologyEvaluation/job/LawsTechnologyEvaluationRemindJob.java index e63518c3f..1ac1399da 100644 --- a/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/lawsTechnologyEvaluation/job/LawsTechnologyEvaluationRemindJob.java +++ b/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/lawsTechnologyEvaluation/job/LawsTechnologyEvaluationRemindJob.java @@ -1,147 +1,147 @@ -package com.jero.modules.lawsTechnologyEvaluation.job; - -import com.alibaba.fastjson.JSONObject; -import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper; -import com.jero.common.exception.JeroBootException; -import com.jero.modules.lawsOpinionGather.enums.GatherResultEnum; -import com.jero.modules.lawsTechnologyEvaluation.entity.LawsTechnologyEvaluationEO; -import com.jero.modules.lawsTechnologyEvaluation.entity.LawsTechnologyEvaluationFlowDetailEO; -import com.jero.modules.lawsTechnologyEvaluation.service.ILawsTechnologyEvaluationEOService; -import com.jero.modules.lawsTechnologyEvaluation.service.ILawsTechnologyEvaluationFlowDetailEOService; -import com.jero.modules.project.enums.MsgTypeEnum; -import com.jero.modules.wkflow.feginClient.WorkFlowFeignClient; -import lombok.extern.slf4j.Slf4j; -import org.apache.commons.collections4.CollectionUtils; -import org.apache.commons.lang3.StringUtils; -import org.quartz.Job; -import org.quartz.JobExecutionContext; -import org.quartz.JobExecutionException; -import org.springframework.beans.factory.annotation.Autowired; - -import java.text.SimpleDateFormat; -import java.util.*; -import java.util.stream.Collectors; - -/** - * 法规技术评估 - 定时器 - * 作用:数据还有一天过期时,给代办人发消息 - */ -@Slf4j -public class LawsTechnologyEvaluationRemindJob implements Job { - @Autowired - private WorkFlowFeignClient workFlowFeignClient; - @Autowired - private ILawsTechnologyEvaluationEOService lawsTechnologyEvaluationEOService; - @Autowired - private ILawsTechnologyEvaluationFlowDetailEOService lawsTechnologyEvaluationFlowDetail; - - @Override - public void execute(JobExecutionContext jobExecutionContext) throws JobExecutionException { - QueryWrapper queryWrapper = new QueryWrapper<>(); - queryWrapper.lambda().eq(LawsTechnologyEvaluationEO::getFlowStatus, GatherResultEnum.UNDERWAY.getValue()); - List LawsTechnologyEvaluationEOList = this.lawsTechnologyEvaluationEOService.list(queryWrapper); - if(CollectionUtils.isNotEmpty(LawsTechnologyEvaluationEOList)){ - List LawsTechnologyEvaluationIdList = LawsTechnologyEvaluationEOList.stream().map(LawsTechnologyEvaluationEO::getId).distinct().collect(Collectors.toList()); - - QueryWrapper detailQueryWrapper = new QueryWrapper<>(); - detailQueryWrapper.lambda().in(LawsTechnologyEvaluationFlowDetailEO::getLawsTechnologyEvaluationId,LawsTechnologyEvaluationIdList); - List flowDetailList = this.lawsTechnologyEvaluationFlowDetail.list(detailQueryWrapper); - - SimpleDateFormat sdf = new SimpleDateFormat("yyyy-MM-dd"); - - //获取后一天的时间 - //Calendar calendar=new GregorianCalendar(); - //calendar.setTime(new Date()); - //calendar.add(Calendar.DATE,1); - //Date nextDay = calendar.getTime(); - - //String nextDayStr = sdf.format(nextDay); - - String now = sdf.format(new Date()); - LawsTechnologyEvaluationEOList.forEach(lawsTechnologyEvaluationEO -> { - /*if(StringUtils.equals(nextDayStr,sdf.format(lawsTechnologyEvaluationEO.getEndTime()))){ - - String actiProcInstIds = flowDetailList.stream().filter(flowDetail -> { - boolean flag = false; - if (StringUtils.equals(lawsTechnologyEvaluationEO.getId(), flowDetail.getLawsTechnologyEvaluationId())) { - flag = true; - } - return flag; - }).map(LawsTechnologyEvaluationFlowDetailEO::getActiProcInstId).distinct().collect(Collectors.joining(",")); - - if(StringUtils.isNotEmpty(actiProcInstIds)){ - List userIdList = this.workFlowFeignClient.getTaskAssigneeListByPrcIds(actiProcInstIds); - if(CollectionUtils.isNotEmpty(userIdList)){ - JSONObject sendJsonObject = new JSONObject(); - sendJsonObject.put("msgType", MsgTypeEnum.LAWS_TECHNOLOGY_EVALUATION_EXPIRE_REMIND_MSG.getValue()); - sendJsonObject.put("lawsTechnologyEvaluationId",lawsTechnologyEvaluationEO.getId()); - sendJsonObject.put("serialNumber",lawsTechnologyEvaluationEO.getSerialNumber()); - sendJsonObject.put("userIdList",userIdList); - this.lawsTechnologyEvaluationEOService.workFlowSendMsg(sendJsonObject); - } - } - }*/ - String endTime = sdf.format(lawsTechnologyEvaluationEO.getEndTime()); - int days = 0; - try { - days = (int) (sdf.parse(endTime).getTime() - sdf.parse(now).getTime()) / (24 * 60 * 60 * 1000); - } catch (Exception e) { - e.printStackTrace(); - throw new JeroBootException("日期转换错误"); - } - - if (days == 3) { - //到期前3天 - String actiProcInstIds = flowDetailList.stream().filter(flowDetail -> { - boolean flag = false; - if (StringUtils.equals(lawsTechnologyEvaluationEO.getId(), flowDetail.getLawsTechnologyEvaluationId())) { - flag = true; - } - return flag; - }).map(LawsTechnologyEvaluationFlowDetailEO::getActiProcInstId).distinct().collect(Collectors.joining(",")); - - if(StringUtils.isNotEmpty(actiProcInstIds)){ - //List userIdList = this.workFlowFeignClient.getTaskAssigneeListByPrcIds(actiProcInstIds); - for (String actiProcInstId : actiProcInstIds.split(",")) { - Map map = this.workFlowFeignClient.getTaskInfo(actiProcInstId); - if (!map.isEmpty()) { - JSONObject sendJsonObject = new JSONObject(); - sendJsonObject.put("msgType", MsgTypeEnum.LAWS_TECHNOLOGY_EVALUATION_EXPIRE_REMIND_THREE_DAYS_BEFORE_MSG.getValue()); - sendJsonObject.put("lawsTechnologyEvaluationId",lawsTechnologyEvaluationEO.getId()); - sendJsonObject.put("userId",map.get("userId")); - sendJsonObject.put("taskId",map.get("taskId")); - sendJsonObject.put("taskDefKey",map.get("taskDefKey")); - this.lawsTechnologyEvaluationEOService.workFlowSendMsg(sendJsonObject); - } - } - } - } else if (endTime.equals(now)){ - //当天 - String actiProcInstIds = flowDetailList.stream().filter(flowDetail -> { - boolean flag = false; - if (StringUtils.equals(lawsTechnologyEvaluationEO.getId(), flowDetail.getLawsTechnologyEvaluationId())) { - flag = true; - } - return flag; - }).map(LawsTechnologyEvaluationFlowDetailEO::getActiProcInstId).distinct().collect(Collectors.joining(",")); - - if(StringUtils.isNotEmpty(actiProcInstIds)){ - //List userIdList = this.workFlowFeignClient.getTaskAssigneeListByPrcIds(actiProcInstIds); - for (String actiProcInstId : actiProcInstIds.split(",")) { - Map map = this.workFlowFeignClient.getTaskInfo(actiProcInstId); - if (!map.isEmpty()) { - JSONObject sendJsonObject = new JSONObject(); - sendJsonObject.put("msgType", MsgTypeEnum.LAWS_TECHNOLOGY_EVALUATION_EXPIRE_REMIND_TODAY_MSG.getValue()); - sendJsonObject.put("lawsTechnologyEvaluationId",lawsTechnologyEvaluationEO.getId()); - sendJsonObject.put("userId",map.get("userId")); - sendJsonObject.put("taskId",map.get("taskId")); - sendJsonObject.put("taskDefKey",map.get("taskDefKey")); - this.lawsTechnologyEvaluationEOService.workFlowSendMsg(sendJsonObject); - } - } - } - } - }); - } - } -} +package com.jero.modules.lawsTechnologyEvaluation.job; + +import com.alibaba.fastjson.JSONObject; +import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper; +import com.jero.common.exception.JeroBootException; +import com.jero.modules.lawsOpinionGather.enums.GatherResultEnum; +import com.jero.modules.lawsTechnologyEvaluation.entity.LawsTechnologyEvaluationEO; +import com.jero.modules.lawsTechnologyEvaluation.entity.LawsTechnologyEvaluationFlowDetailEO; +import com.jero.modules.lawsTechnologyEvaluation.service.ILawsTechnologyEvaluationEOService; +import com.jero.modules.lawsTechnologyEvaluation.service.ILawsTechnologyEvaluationFlowDetailEOService; +import com.jero.modules.project.enums.MsgTypeEnum; +import com.jero.modules.wkflow.feginClient.WorkFlowFeignClient; +import lombok.extern.slf4j.Slf4j; +import org.apache.commons.collections4.CollectionUtils; +import org.apache.commons.lang3.StringUtils; +import org.quartz.Job; +import org.quartz.JobExecutionContext; +import org.quartz.JobExecutionException; +import org.springframework.beans.factory.annotation.Autowired; + +import java.text.SimpleDateFormat; +import java.util.*; +import java.util.stream.Collectors; + +/** + * 法规技术评估 - 定时器 + * 作用:数据还有一天过期时,给代办人发消息 + */ +@Slf4j +public class LawsTechnologyEvaluationRemindJob implements Job { + @Autowired + private WorkFlowFeignClient workFlowFeignClient; + @Autowired + private ILawsTechnologyEvaluationEOService lawsTechnologyEvaluationEOService; + @Autowired + private ILawsTechnologyEvaluationFlowDetailEOService lawsTechnologyEvaluationFlowDetail; + + @Override + public void execute(JobExecutionContext jobExecutionContext) throws JobExecutionException { + QueryWrapper queryWrapper = new QueryWrapper<>(); + queryWrapper.lambda().eq(LawsTechnologyEvaluationEO::getFlowStatus, GatherResultEnum.UNDERWAY.getValue()); + List LawsTechnologyEvaluationEOList = this.lawsTechnologyEvaluationEOService.list(queryWrapper); + if(CollectionUtils.isNotEmpty(LawsTechnologyEvaluationEOList)){ + List LawsTechnologyEvaluationIdList = LawsTechnologyEvaluationEOList.stream().map(LawsTechnologyEvaluationEO::getId).distinct().collect(Collectors.toList()); + + QueryWrapper detailQueryWrapper = new QueryWrapper<>(); + detailQueryWrapper.lambda().in(LawsTechnologyEvaluationFlowDetailEO::getLawsTechnologyEvaluationId,LawsTechnologyEvaluationIdList); + List flowDetailList = this.lawsTechnologyEvaluationFlowDetail.list(detailQueryWrapper); + + SimpleDateFormat sdf = new SimpleDateFormat("yyyy-MM-dd"); + + //获取后一天的时间 + //Calendar calendar=new GregorianCalendar(); + //calendar.setTime(new Date()); + //calendar.add(Calendar.DATE,1); + //Date nextDay = calendar.getTime(); + + //String nextDayStr = sdf.format(nextDay); + + String now = sdf.format(new Date()); + LawsTechnologyEvaluationEOList.forEach(lawsTechnologyEvaluationEO -> { + /*if(StringUtils.equals(nextDayStr,sdf.format(lawsTechnologyEvaluationEO.getEndTime()))){ + + String actiProcInstIds = flowDetailList.stream().filter(flowDetail -> { + boolean flag = false; + if (StringUtils.equals(lawsTechnologyEvaluationEO.getId(), flowDetail.getLawsTechnologyEvaluationId())) { + flag = true; + } + return flag; + }).map(LawsTechnologyEvaluationFlowDetailEO::getActiProcInstId).distinct().collect(Collectors.joining(",")); + + if(StringUtils.isNotEmpty(actiProcInstIds)){ + List userIdList = this.workFlowFeignClient.getTaskAssigneeListByPrcIds(actiProcInstIds); + if(CollectionUtils.isNotEmpty(userIdList)){ + JSONObject sendJsonObject = new JSONObject(); + sendJsonObject.put("msgType", MsgTypeEnum.LAWS_TECHNOLOGY_EVALUATION_EXPIRE_REMIND_MSG.getValue()); + sendJsonObject.put("lawsTechnologyEvaluationId",lawsTechnologyEvaluationEO.getId()); + sendJsonObject.put("serialNumber",lawsTechnologyEvaluationEO.getSerialNumber()); + sendJsonObject.put("userIdList",userIdList); + this.lawsTechnologyEvaluationEOService.workFlowSendMsg(sendJsonObject); + } + } + }*/ + String endTime = sdf.format(lawsTechnologyEvaluationEO.getEndTime()); + long days = 0; + try { + days = (sdf.parse(endTime).getTime() - sdf.parse(now).getTime()) / (24 * 60 * 60 * 1000L); + } catch (Exception e) { + e.printStackTrace(); + throw new JeroBootException("日期转换错误"); + } + + if (days == 3) { + //到期前3天 + String actiProcInstIds = flowDetailList.stream().filter(flowDetail -> { + boolean flag = false; + if (StringUtils.equals(lawsTechnologyEvaluationEO.getId(), flowDetail.getLawsTechnologyEvaluationId())) { + flag = true; + } + return flag; + }).map(LawsTechnologyEvaluationFlowDetailEO::getActiProcInstId).distinct().collect(Collectors.joining(",")); + + if(StringUtils.isNotEmpty(actiProcInstIds)){ + //List userIdList = this.workFlowFeignClient.getTaskAssigneeListByPrcIds(actiProcInstIds); + for (String actiProcInstId : actiProcInstIds.split(",")) { + Map map = this.workFlowFeignClient.getTaskInfo(actiProcInstId); + if (!map.isEmpty()) { + JSONObject sendJsonObject = new JSONObject(); + sendJsonObject.put("msgType", MsgTypeEnum.LAWS_TECHNOLOGY_EVALUATION_EXPIRE_REMIND_THREE_DAYS_BEFORE_MSG.getValue()); + sendJsonObject.put("lawsTechnologyEvaluationId",lawsTechnologyEvaluationEO.getId()); + sendJsonObject.put("userId",map.get("userId")); + sendJsonObject.put("taskId",map.get("taskId")); + sendJsonObject.put("taskDefKey",map.get("taskDefKey")); + this.lawsTechnologyEvaluationEOService.workFlowSendMsg(sendJsonObject); + } + } + } + } else if (endTime.equals(now)){ + //当天 + String actiProcInstIds = flowDetailList.stream().filter(flowDetail -> { + boolean flag = false; + if (StringUtils.equals(lawsTechnologyEvaluationEO.getId(), flowDetail.getLawsTechnologyEvaluationId())) { + flag = true; + } + return flag; + }).map(LawsTechnologyEvaluationFlowDetailEO::getActiProcInstId).distinct().collect(Collectors.joining(",")); + + if(StringUtils.isNotEmpty(actiProcInstIds)){ + //List userIdList = this.workFlowFeignClient.getTaskAssigneeListByPrcIds(actiProcInstIds); + for (String actiProcInstId : actiProcInstIds.split(",")) { + Map map = this.workFlowFeignClient.getTaskInfo(actiProcInstId); + if (!map.isEmpty()) { + JSONObject sendJsonObject = new JSONObject(); + sendJsonObject.put("msgType", MsgTypeEnum.LAWS_TECHNOLOGY_EVALUATION_EXPIRE_REMIND_TODAY_MSG.getValue()); + sendJsonObject.put("lawsTechnologyEvaluationId",lawsTechnologyEvaluationEO.getId()); + sendJsonObject.put("userId",map.get("userId")); + sendJsonObject.put("taskId",map.get("taskId")); + sendJsonObject.put("taskDefKey",map.get("taskDefKey")); + this.lawsTechnologyEvaluationEOService.workFlowSendMsg(sendJsonObject); + } + } + } + } + }); + } + } +} diff --git a/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/lawsTechnologyEvaluation/service/impl/LawsTechnologyEvaluationEOServiceImpl.java b/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/lawsTechnologyEvaluation/service/impl/LawsTechnologyEvaluationEOServiceImpl.java index 3c856d5f4..c25ea69ff 100644 --- a/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/lawsTechnologyEvaluation/service/impl/LawsTechnologyEvaluationEOServiceImpl.java +++ b/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/lawsTechnologyEvaluation/service/impl/LawsTechnologyEvaluationEOServiceImpl.java @@ -16,6 +16,7 @@ import com.jero.modules.document.enums.FieldTypeEnum; import com.jero.modules.document.mapper.BussDocumentLibraryEOMapper; import com.jero.modules.document.service.impl.BussDocumentLibraryEOServiceImpl; import com.jero.modules.enums.DictCodeEnum; +import com.jero.modules.feishu.enums.TemplateInfoEnum2; import com.jero.modules.feishu.service.IFeishuService; import com.jero.modules.feishu.vo.FeishuMsg2Vo; import com.jero.modules.lawsOpinionGather.enums.GatherResultEnum; @@ -652,6 +653,7 @@ public class LawsTechnologyEvaluationEOServiceImpl extends ServiceImpl().lambda().eq(SysUser::getId, currentUserId)); initiator = currentUser.getUsername(); - cnContentUpper = "您好,您提交的评估结果已通过"; + cnContentUpper = "您好,您提交的评估结果已通过。"; cnContentLower = "编号:" + lawsTechnologyEvaluationEO.getSerialNumber() + "\n标题: " + lawsTechnologyEvaluationEO.getTitle() + "\n发起人: " + initiator + "\n截止时间: " + endTime; - enContentUpper = "Hello! The assessment result you submitted has passed"; - enContentLower = "Regulation No :" + lawsTechnologyEvaluationEO.getSerialNumber() + - "\nTitle: " + bussDocumentLibraryEO.getTitleEn() + - "\nInitiator: " + initiator + - "\nDue Date: " + endTime; + enContentUpper = "Hello! The assessment result you submitted has passed."; +// enContentLower = "Regulation No :" + lawsTechnologyEvaluationEO.getSerialNumber() + +// "\nTitle: " + bussDocumentLibraryEO.getTitleEn() + +// "\nInitiator: " + initiator + +// "\nDue Date: " + endTime; LawsTechnologyEvaluationFlowDetailEO flowDetailEO = flowDetailEOMapper.queryByEvaluationId(lawsTechnologyEvaluationId,jsonObject.getString("evaluationId")); if (ObjectUtils.isNotEmpty(flowDetailEO)) { hrefFeishu = backUrl + "/evaluationProcess?taskDefinitionKey=fqrsc&taskIds="+ taskId +"&prcType=6&prcNum="+ flowDetailEO.getPrcNum() +"&prcId="+ flowDetailEO.getActiProcInstId() +"&router=%2FregulatoryAssessmentTasks&isDisabled=true"; @@ -788,18 +801,23 @@ public class LawsTechnologyEvaluationEOServiceImpl extends ServiceImpl().lambda().eq(SysUser::getId, currentUserId)); initiator = currentUser.getUsername(); - cnContentUpper = "您好,您提交的评估结果被退回,请及时查看处理"; + cnContentUpper = "您好,您提交的评估结果被退回,请及时查看处理。"; cnContentLower = "编号:" + lawsTechnologyEvaluationEO.getSerialNumber() + "\n标题: " + lawsTechnologyEvaluationEO.getTitle() + "\n发起人: " + initiator + "\n截止时间: " + endTime; - enContentUpper = "Hello! The assessment result you submitted has been rejected. Please check and address it in a timely manner"; - enContentLower = "Regulation No :" + lawsTechnologyEvaluationEO.getSerialNumber() + - "\nTitle: " + bussDocumentLibraryEO.getTitleEn() + - "\nInitiator: " + initiator + - "\nDue Date: " + endTime; + enContentUpper = "Hello! The assessment result you submitted has been rejected. Please check and address it in a timely manner."; +// enContentLower = "Regulation No :" + lawsTechnologyEvaluationEO.getSerialNumber() + +// "\nTitle: " + bussDocumentLibraryEO.getTitleEn() + +// "\nInitiator: " + initiator + +// "\nDue Date: " + endTime; LawsTechnologyEvaluationFlowDetailEO flowDetailEO = flowDetailEOMapper.queryByEvaluationId(lawsTechnologyEvaluationId,jsonObject.getString("evaluators")); if (ObjectUtils.isNotEmpty(flowDetailEO)) { @@ -831,31 +849,38 @@ public class LawsTechnologyEvaluationEOServiceImpl extends ServiceImpl userIdList, String hrefFeishu, String initiator, String initiatorEn, LawsTechnologyEvaluationEO lawsTechnologyEvaluationEO, String endTime, BussDocumentLibraryEO bussDocumentLibraryEO, String cnContentUpper, String enContentUpper) { + //飞书消息(模板-20230410) + Map params = new HashMap<>(); + params.put("contentInfoFeiCn",cnContentUpper); + params.put("contentInfoFeiEn",enContentUpper); + params.put("userIdList",userIdList); + params.put("back_url",hrefFeishu); + params.put("titleCn"," "+lawsTechnologyEvaluationEO.getTitle()); + if(ObjectUtils.isNotEmpty(bussDocumentLibraryEO)){ + params.put("titleEn"," "+bussDocumentLibraryEO.getTitleEn()); + }else{ + params.put("titleEn",""); + } + params.put("regulationNo"," "+lawsTechnologyEvaluationEO.getSerialNumber()); + params.put("initiator"," "+initiator); + params.put("carTitleCn", TemplateInfoEnum2.REGULATION_TECHNICAL_ASSESSMENT.getNameCn()); + params.put("carTitleEn",TemplateInfoEnum2.REGULATION_TECHNICAL_ASSESSMENT.getNameEn()); + if(StringUtils.equals(msgType, MsgTypeEnum.LAWS_TECHNOLOGY_EVALUATION_EXPIRE_REMIND_TODAY_MSG.getValue()) + || StringUtils.equals(msgType, MsgTypeEnum.LAWS_TECHNOLOGY_EVALUATION_EXPIRE_REMIND_THREE_DAYS_BEFORE_MSG.getValue())){ + params.put("initiatorEn"," "+initiatorEn); + }else{ + params.put("initiatorEn"," "+initiator); + } + params.put("dueDate"," "+endTime); + feishuService.sendMessageRegulationOpinionCollection(TemplateInfoEnum2.REGULATION_TECHNICAL_ASSESSMENT.getValue(),params); + } + @Override public Result batchCompleteTask(JSONObject jsonObject) { String ids = jsonObject.getString("ids"); diff --git a/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/project/enums/CertificationInventoryFlowStatusEnum.java b/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/project/enums/CertificationInventoryFlowStatusEnum.java index 57367ddc9..77397cd88 100644 --- a/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/project/enums/CertificationInventoryFlowStatusEnum.java +++ b/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/project/enums/CertificationInventoryFlowStatusEnum.java @@ -21,6 +21,7 @@ public enum CertificationInventoryFlowStatusEnum { * 结果待审查 责任人提交后认证工程师未审查 * 审查通过 责任人提交后认证工程师审查通过 * 审查退回 责任人提交后认证工程师审查退回 + * 不涉及 2023-04-12修改UAT需求增加,如果交付物类型为 N/A的话,会将流程状态更新为 不涉及。 */ LIST_TO_BE_RELEASED("清单待发布","List to be released","List to be released"), @@ -33,6 +34,7 @@ public enum CertificationInventoryFlowStatusEnum { RESULTS_TO_BE_REVIEWED("结果待审查","Results to be reviewed","Results to be reviewed"), REVIEW_AND_PASS("审查通过","Review and pass","Review and pass"), REVIEW_AND_RETURN("审查退回","Review and return","Review and return"), + UNINVOLVED("不涉及","NA","NA"), ; diff --git a/jero-web/src/views/projectManagement/components/certificationList/index.vue b/jero-web/src/views/projectManagement/components/certificationList/index.vue index d3aad6ab5..eea0c4d17 100644 --- a/jero-web/src/views/projectManagement/components/certificationList/index.vue +++ b/jero-web/src/views/projectManagement/components/certificationList/index.vue @@ -1111,6 +1111,11 @@ let notConditions = [] for (let i = 0; i < this.selectedRowKeysList.length; i++) { if ((this.selectedRowKeysList[i].flowStatus == 'List to be released' && + this.selectedRowKeysList[i].deliverableType == '1635545748968783874') || + (this.selectedRowKeysList[i].flowStatus == 'Certification returned' && + this.selectedRowKeysList[i].deliverableType == '1635545748968783874') ) { + ids.push(this.selectedRowKeysList[i].id) + } else if ((this.selectedRowKeysList[i].flowStatus == 'List to be released' && this.selectedRowKeysList[i].endTime) || (this.selectedRowKeysList[i].flowStatus == 'Certification returned' && this.selectedRowKeysList[i].endTime)) { @@ -1921,7 +1926,7 @@ content: prompt, onOk() { if (NAId && NAId.length > 0) { - this.NASubmitTask(NAId, ids, notConditions, data) + _this.NASubmitTask(NAId, ids, notConditions, data) } if (ids && ids.length > 0) { let query = { @@ -1949,10 +1954,10 @@ NASubmitTask(NAId, ids, notConditions, data) { let _this = this let query = { - 'projectLibraryId': _this.$route.query.id, + 'flowStatus': 'NA', 'ids': NAId.join(',') } - postAction('/project/projectCertificationInventoryEO/submitTask', query).then((res) => { + postAction('/project/projectCertificationInventoryEO/updateStatusBatch', query).then((res) => { if (res.success) { if (ids && ids.length > 0) { } else {