diff --git a/jero-boot/db/蔚来标准sql/dev_2nd_period.sql b/jero-boot/db/蔚来标准sql/dev_2nd_period.sql index bbfb3c6f4..41040c0f7 100644 --- a/jero-boot/db/蔚来标准sql/dev_2nd_period.sql +++ b/jero-boot/db/蔚来标准sql/dev_2nd_period.sql @@ -643,4 +643,7 @@ ALTER TABLE `project_task_planning` ADD COLUMN `five` datetime(0) NULL COMMENT '预生产阶段' AFTER `four`, ADD COLUMN `six` datetime(0) NULL COMMENT '试产阶段' AFTER `five`, ADD COLUMN `seven` datetime(0) NULL COMMENT '小批量生产阶段' AFTER `six`, - ADD COLUMN `eight` datetime(0) NULL COMMENT '大规模生产阶段' AFTER `seven`; \ No newline at end of file + ADD COLUMN `eight` datetime(0) NULL COMMENT '大规模生产阶段' AFTER `seven`; + +-- 工作流数据库-增加固定数据 2023-05-17 未同步生产环境 +INSERT INTO `t_form`(`OBJECT_ID`, `CODE`, `CREATE_TIME`, `WIDGET_JSON`, `JSON`, `NAME`, `SHOW_KEY`, `IS_DELETED`, `MODEL_ID`, `JSON_EVAL`, `HTML`, `RUN_TYPE`, `CATEGORY_ID`, `HTML_READONLY`) VALUES ('xgjfwlc', '0007', '2023-05-17 13:52:26', NULL, NULL, '修改交付物流程', NULL, 0, '15007', NULL, NULL, 'json', '4bdf0b396b4aa6ea10dd5e19956a1e22', NULL); diff --git a/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/project/enums/OperatorTypeEnum.java b/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/project/enums/OperatorTypeEnum.java index 64790607f..d72025ea0 100644 --- a/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/project/enums/OperatorTypeEnum.java +++ b/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/project/enums/OperatorTypeEnum.java @@ -90,6 +90,9 @@ public enum OperatorTypeEnum { LAWS_INVENTORY_VERIFY_CITE_DELIVERABLE("法规清单-验证-引用交付物","lawsInventoryVerifyCiteDeliverable"), LAWS_INVENTORY_STUDIO_COPY("法规清单-studio复制","lawsInventoryStudioCopy"), LAWS_INVENTORY_REGULATION_OWNER_COPY("法规清单-法规工程师复制","lawsInventoryRegulationOwnerCopy"), + LAWS_INVENTORY_ALL_RESET_FLOW("法规清单-设计和验证-重置流程","lawsInventoryAllResetFlow"), + LAWS_INVENTORY_DESIGN_RESET_FLOW("法规清单-设计-重置流程","lawsInventoryDesignResetFlow"), + LAWS_INVENTORY_VERIFY_RESET_FLOW("法规清单-验证-重置流程","lawsInventoryVerifyResetFlow"), /** * 待办中心-将法规工程师的法规清单确认待办任务转为已办 diff --git a/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/project/service/impl/ProjectLawsInventoryEOServiceImpl.java b/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/project/service/impl/ProjectLawsInventoryEOServiceImpl.java index 38ac9efbf..04a24be20 100644 --- a/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/project/service/impl/ProjectLawsInventoryEOServiceImpl.java +++ b/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/project/service/impl/ProjectLawsInventoryEOServiceImpl.java @@ -6704,8 +6704,11 @@ public class ProjectLawsInventoryEOServiceImpl extends ServiceImpl change(JSONObject parmas) { String ids = parmas.getString("ids"); String projectLibraryId = parmas.getString("projectLibraryId"); + String operateType = parmas.getString("operateType"); if (StringUtils.isNotEmpty(ids)) { + List piFlowTypeList = new ArrayList<>(); + QueryWrapper queryWrapper = new QueryWrapper<>(); queryWrapper.lambda().in(ProjectLawsInventoryEO::getId, Arrays.asList(ids.split(","))); queryWrapper.lambda().eq(ProjectLawsInventoryEO::getProjectLibraryId, projectLibraryId); @@ -6730,20 +6733,32 @@ public class ProjectLawsInventoryEOServiceImpl extends ServiceImpl processInfoQueryWrap = new QueryWrapper<>(); processInfoQueryWrap.lambda().in(ProcessInfoEO::getProjectLawsInventoryId, idList); + processInfoQueryWrap.lambda().in(ProcessInfoEO::getFlowType,piFlowTypeList); List processInfoEOList = this.processInfoEOService.list(processInfoQueryWrap); - List actiProcInstIdList = processInfoEOList.stream().filter(processInfo -> { - boolean flag = false; - if (StringUtils.equals(processInfo.getFlowType(), FlowTypeEnum.SJFHXSHLC.getValue()) || StringUtils.equals(processInfo.getFlowType(), FlowTypeEnum.YZFHXSCLC.getValue())) { - flag = true; - } - return flag; - }).map(ProcessInfoEO::getActiProcInstId).distinct().collect(Collectors.toList()); + List actiProcInstIdList = processInfoEOList.stream().map(ProcessInfoEO::getActiProcInstId).distinct().collect(Collectors.toList()); pIds = actiProcInstIdList.stream().map(String::valueOf).collect(Collectors.joining(",")); @@ -6835,6 +6850,7 @@ public class ProjectLawsInventoryEOServiceImpl extends ServiceImpl concat(pli.serial_number,' ',bdl.title_en) as standard_info, - pi.flow_type, + (case pi.flow_type when '32' THEN '2' when '34' THEN '4' else pi.flow_type END) as flow_type, pi.create_by, pi.end_time, pi.status, @@ -173,7 +173,7 @@ concat(pli.serial_number,' ',bdl.title_en) as standard_info, - pi.flow_type, + (case pi.flow_type when '32' THEN '2' when '34' THEN '4' else pi.flow_type END) as flow_type, pi.create_by, pi.end_time, pi.STATUS, diff --git a/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/todoCenter/service/impl/ProcessInfoEOServiceImpl.java b/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/todoCenter/service/impl/ProcessInfoEOServiceImpl.java index ea504c0db..01c1ba96f 100644 --- a/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/todoCenter/service/impl/ProcessInfoEOServiceImpl.java +++ b/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/todoCenter/service/impl/ProcessInfoEOServiceImpl.java @@ -224,6 +224,8 @@ public class ProcessInfoEOServiceImpl extends ServiceImpl params) { //需要清除数据的法规清单ids String ids = (String)params.get("ids"); + String operateType = (String)params.get("operateType"); List projectLawsInventoryIdList = Arrays.asList(ids.split(",")); if(CollectionUtils.isNotEmpty(projectLawsInventoryIdList)){ //清除清单确认相关数据 @@ -404,17 +407,31 @@ public class ProcessInfoEOServiceImpl extends ServiceImpl flowTypeList = new ArrayList<>(); - flowTypeList.add(FlowTypeEnum.RWQRLC.getValue()); - flowTypeList.add(FlowTypeEnum.SJFHXSHLC.getValue()); - // flowTypeList.add(FlowTypeEnum.PREHOMOQRLC.getValue()); - flowTypeList.add(FlowTypeEnum.YZFHXSCLC.getValue()); + + // 区分重置设计、验证、全部流程 + if (StringUtils.equals(operateType, OperatorTypeEnum.LAWS_INVENTORY_ALL_RESET_FLOW.getValue())) { + flowTypeList.add(FlowTypeEnum.SJFHXSHLC.getValue()); + flowTypeList.add(FlowTypeEnum.YZFHXSCLC.getValue()); + flowTypeList.add(FlowTypeEnum.SJ_XGJFWLC.getValue()); + flowTypeList.add(FlowTypeEnum.YZ_XGJFWLC.getValue()); + } else if (StringUtils.equals(operateType, OperatorTypeEnum.LAWS_INVENTORY_DESIGN_RESET_FLOW.getValue())) { + flowTypeList.add(FlowTypeEnum.SJFHXSHLC.getValue()); + flowTypeList.add(FlowTypeEnum.SJ_XGJFWLC.getValue()); + } else if (StringUtils.equals(operateType, OperatorTypeEnum.LAWS_INVENTORY_VERIFY_RESET_FLOW.getValue())) { + flowTypeList.add(FlowTypeEnum.YZFHXSCLC.getValue()); + flowTypeList.add(FlowTypeEnum.YZ_XGJFWLC.getValue()); + } +// flowTypeList.add(FlowTypeEnum.RWQRLC.getValue()); +// flowTypeList.add(FlowTypeEnum.SJFHXSHLC.getValue()); +// // flowTypeList.add(FlowTypeEnum.PREHOMOQRLC.getValue()); +// flowTypeList.add(FlowTypeEnum.YZFHXSCLC.getValue()); //根据法规清单id,查询待办中心数据 QueryWrapper processInfoQueryWrap = new QueryWrapper<>(); - processInfoQueryWrap.lambda().in(ProcessInfoEO::getProjectLawsInventoryId,projectLawsInventoryIdList); - processInfoQueryWrap.lambda().in(ProcessInfoEO::getFlowType,flowTypeList); + processInfoQueryWrap.lambda().in(ProcessInfoEO::getProjectLawsInventoryId, projectLawsInventoryIdList); + processInfoQueryWrap.lambda().in(ProcessInfoEO::getFlowType, flowTypeList); List processInfoEOList = this.list(processInfoQueryWrap); - if(CollectionUtils.isNotEmpty(processInfoEOList)){ + if (CollectionUtils.isNotEmpty(processInfoEOList)) { List processInfoIdList = processInfoEOList.stream().map(ProcessInfoEO::getId).distinct().collect(Collectors.toList()); /*QueryWrapper detailRemoveWrap = new QueryWrapper<>(); detailRemoveWrap.lambda().in(ProcessInfoDetailEO::getProcessInfoId,processInfoIdList); @@ -501,6 +518,8 @@ public class ProcessInfoEOServiceImpl extends ServiceImpl> queryComplianceProcessHistoryList(@RequestParam Map params) { + List list = processHistoryEOService.queryComplianceProcessHistoryList(params); + return Result.OK(list); + } + } diff --git a/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/wkflow/controller/workFlowController.java b/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/wkflow/controller/workFlowController.java index 0d4502e30..66c5596d5 100644 --- a/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/wkflow/controller/workFlowController.java +++ b/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/wkflow/controller/workFlowController.java @@ -76,6 +76,9 @@ public class workFlowController { }else if(StringUtils.equals(type,FlowTypeEnum.FGJSPG.getValue())){ jsonObject.put("processDefinitionKey", FlowTypeEnum.FGJSPG.getProcessDefinitionKey()); return this.startLawsTechnologyEvaluationProcess(jsonObject); + }else if(StringUtils.equals(type,FlowTypeEnum.XGJFWLC.getValue())){ + jsonObject.put("id", FlowTypeEnum.XGJFWLC.getProcessDefinitionKey()); + return this.activiti_define_start(jsonObject); }else{ return null; } diff --git a/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/wkflow/enums/FlowTypeEnum.java b/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/wkflow/enums/FlowTypeEnum.java index 369aa2614..a39fdb049 100644 --- a/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/wkflow/enums/FlowTypeEnum.java +++ b/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/wkflow/enums/FlowTypeEnum.java @@ -17,6 +17,9 @@ public enum FlowTypeEnum { FGJSPG("6","法规技术评估流程","FGJSPG","法规技术评估流程","fgjspglc","法规技术评估","Regulatory and technical assessment"), QDQR("10","清单确认","QDQR","清单确认流程","qdqr","法规清单发布","Release of regulatory list"), CERTIFICATION_LC("21","认证流程","CERTIFICATION_LC","认证流程","certification_lc","Pre-Homo流程","Pre-Homo flow"), + XGJFWLC("31","修改交付物流程","XGJFWLC","修改交付物流程","xgjfwlc","修改交付物流程","Update Deliverable"), + SJ_XGJFWLC("32","设计-修改交付物流程","SJ_XGJFWLC","设计-修改交付物流程","sj_xgjfwlc","设计-修改交付物流程","Design Update Deliverable"), + YZ_XGJFWLC("34","验证-修改交付物流程","YZ_XGJFWLC","验证-修改交付物流程","yz_xgjfwlc","验证-修改交付物流程","Verify Update Deliverable"), ; private String value; diff --git a/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/wkflow/service/IProcessHistoryEOService.java b/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/wkflow/service/IProcessHistoryEOService.java index 347b0e17f..5c9d6adcd 100644 --- a/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/wkflow/service/IProcessHistoryEOService.java +++ b/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/wkflow/service/IProcessHistoryEOService.java @@ -70,4 +70,11 @@ public interface IProcessHistoryEOService extends IService { Result processCall(JSONObject jsonObject); void deleteBiActiProcInstIdList(List actiProcInstIdList); + + /** + * 查询符合性流程历史 + * @param params + * @return + */ + List queryComplianceProcessHistoryList(Map params); } diff --git a/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/wkflow/service/impl/ProcessHistoryEOServiceImpl.java b/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/wkflow/service/impl/ProcessHistoryEOServiceImpl.java index f128403b6..9c57fb67f 100644 --- a/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/wkflow/service/impl/ProcessHistoryEOServiceImpl.java +++ b/jero-boot/jero-boot-modules/src/main/java/com/jero/modules/wkflow/service/impl/ProcessHistoryEOServiceImpl.java @@ -180,17 +180,17 @@ public class ProcessHistoryEOServiceImpl extends ServiceImpl queryComplianceProcessHistoryList(Map params) { + String cut = (String) params.get("cut"); + String projectLawsInventoryId = (String) params.get("projectLawsInventoryId"); + if (StringUtils.isEmpty(projectLawsInventoryId)) { + throw new JeroBootException("法规清单id不能为空!"); + } + String flowType = (String) params.get("flowType"); + List flowTypeList = new ArrayList<>(); + flowTypeList.add(flowType); + if(StringUtils.equals(flowType,FlowTypeEnum.SJFHXSHLC.getValue())){ + flowTypeList.add(FlowTypeEnum.SJ_XGJFWLC.getValue()); + }else if(StringUtils.equals(flowType,FlowTypeEnum.YZFHXSCLC.getValue())){ + flowTypeList.add(FlowTypeEnum.YZ_XGJFWLC.getValue()); + } + QueryWrapper piQueryWrap = new QueryWrapper<>(); + piQueryWrap.lambda().eq(ProcessInfoEO::getProjectLawsInventoryId, projectLawsInventoryId); + piQueryWrap.lambda().in(ProcessInfoEO::getFlowType, flowTypeList); + List piInfoList = this.processInfoEOService.list(piQueryWrap); + List actiProcInstIdList = piInfoList.stream().map(ProcessInfoEO::getActiProcInstId).distinct().collect(Collectors.toList()); + + List processHistoryEOList = null; + if(CollectionUtils.isNotEmpty(actiProcInstIdList)){ + QueryWrapper queryWrapper = new QueryWrapper<>(); + queryWrapper.orderByAsc("create_time"); + queryWrapper.lambda().in(ProcessHistoryEO::getActiProcInstId, actiProcInstIdList); + processHistoryEOList = this.baseMapper.selectList(queryWrapper); + this.disposeData(processHistoryEOList, cut); + } + return processHistoryEOList; + } } diff --git a/jero-web/src/common/lang/en-us.js b/jero-web/src/common/lang/en-us.js index 78cb0073e..28d744d1e 100644 --- a/jero-web/src/common/lang/en-us.js +++ b/jero-web/src/common/lang/en-us.js @@ -1835,4 +1835,8 @@ module.exports = { expectedDeliveryTime:'Expected Delivery Time', changeAuthor:'Change Author', requireddataisnull:'Required data is null', + theProcessThatNeedsToBeReset:'The process that needs to be reset', + toResubmit:'To Resubmit', + selectDesignConformanceAsConformance:'Select Design Conformance verification process state as Conformance or Verify conformance verification process state as conformance obtained data', + submissionProcess:'Submission Process', } \ No newline at end of file diff --git a/jero-web/src/common/lang/zh-cn.js b/jero-web/src/common/lang/zh-cn.js index b85aebf9b..f92664c4a 100644 --- a/jero-web/src/common/lang/zh-cn.js +++ b/jero-web/src/common/lang/zh-cn.js @@ -1936,4 +1936,8 @@ module.exports = { expectedDeliveryTime:'预计交付时间', changeAuthor:'更改作者', requireddataisnull:'必填数据为空', + theProcessThatNeedsToBeReset:'需要重置的流程', + toResubmit:'重新提交', + selectDesignConformanceAsConformance:'请选择设计符合性确认流程状态为符合或验证符合性确认流程状态为符合的数据', + submissionProcess:'提交流程', } \ No newline at end of file diff --git a/jero-web/src/views/projectManagement/components/listOfRegulations.vue b/jero-web/src/views/projectManagement/components/listOfRegulations.vue index a184b8a39..08feba3fc 100644 --- a/jero-web/src/views/projectManagement/components/listOfRegulations.vue +++ b/jero-web/src/views/projectManagement/components/listOfRegulations.vue @@ -199,6 +199,12 @@ {{ $t('customize') }} + +
+ + {{ $t('toResubmit') }} +
@@ -675,6 +719,7 @@ import viewFileModel from '@/components/viewFileModel/index' import globalAdvancedQuery from '@/components/globalAdvancedQuery/index' import modifyOperator from './modifyOperator' + import toResubmitForm from './toResubmitForm' import batchSettingPersonnel from './batchSettingPersonnel' import { getAction, postAction, downloadFile, deleteAction } from '@/api/manage' import { ResizeHeader, ResizeColumnProvide } from '@/mixins/header' @@ -700,13 +745,16 @@ listOfRegulationsView, viewFileModel, designCompliance, - modifyOperator + modifyOperator, + toResubmitForm }, mixins: [ResizeColumnProvide, ResizeHeader], data() { return { toggleSearchStatus: false, visibleQuestion: false, + visibleReset: false, + confirmLoadingReset: false, confirmLoadingQuestion: false, isDesignCompliance: false, isVerifyingCompliance: false, @@ -716,6 +764,16 @@ total: 0, roleSwitchingList: [], formInlineQuestion: {}, + formInlineReset: {}, + rulesRoleReset: { + operateType: [ + { + required: true, + message: this.$t('processReset') + this.$t('cannotEmpty'), + trigger: 'change' + } + ] + }, rulesRoleQuestion: { expeditingType: [ { @@ -735,6 +793,20 @@ name: this.$t('validationComplianceProcess') } ], + processResetList: [ + { + value: 'lawsInventoryAllResetFlow', + name: this.$t('whole') + }, + { + value: 'lawsInventoryDesignResetFlow', + name: this.$t('designComplianceProcess') + }, + { + value: 'lawsInventoryVerifyResetFlow', + name: this.$t('validationComplianceProcess') + } + ], listTitle: '', orderBy: '1', orderByField: '', @@ -2168,13 +2240,46 @@ // } // } if (isTrue) { - this.changeInterface(selectedRowKeys) + this.formInlineReset = {} + this.$nextTick(() => { + this.$refs.ruleFormReset.clearValidate() + }) + // this.changeInterface(selectedRowKeys) + this.visibleReset = true } } else { this.$message.warning(this.$t('selectLeastOne')) } }, - + handleOkReset() { + this.$refs.ruleFormReset.validate(valid => { + if (valid) { + let _this = this + _this.confirmLoadingReset = true + let idList = JSON.parse(JSON.stringify(_this.selectedRowKeys)) + postAction('/project/projectLawsInventoryEO/change', { + ids: idList.join(','), + projectLibraryId: _this.$route.query.id, + operateType: _this.formInlineReset.operateType + }).then((res) => { + if (res.success) { + _this.$message.success(_this.$t('OperationSuccessful')) + _this.confirmLoadingReset = false + _this.visibleReset = false + _this.selectedRowKeys = [] + _this.pageNo = 1 + _this.getList() + } else { + _this.$message.warning(_this.$t('operationFailed')) + _this.confirmLoadingReset = false + } + }) + } + }) + }, + handleCancelReset() { + this.visibleReset = false + }, //流程重置接口 changeInterface() { let _this = this @@ -2858,9 +2963,9 @@ } if (dataList[i].designFlowStatus == 'List to be checked' || dataList[i].designFlowStatus == 'Duty Person Rejected') { if (dataList[i].designDeliverableType && dataList[i].designDutyId && dataList[i].designDueDate) { - if (dataList[i].designDeliverableType == '1645667531513237506'){ + if (dataList[i].designDeliverableType == '1645667531513237506') { - }else{ + } else { this.requestsNum++ this.startProcessList.push({ dataList: dataList[i], @@ -2876,9 +2981,9 @@ } if (dataList[i].verifyFlowStatus == 'List to be checked' || dataList[i].verifyFlowStatus == 'Duty Person Rejected') { if (dataList[i].verifyDeliverableType && dataList[i].verifyDutyId && dataList[i].verifyDueDate) { - if (dataList[i].verifyDeliverableType == '1645667531513237506'){ + if (dataList[i].verifyDeliverableType == '1645667531513237506') { - }else{ + } else { this.requestsNum++ this.startProcessList.push({ dataList: dataList[i], @@ -3121,6 +3226,39 @@ }, download(item) { downloadFile('/sys/common/downLoadFile', item.fileName, { id: item.id, userName: this.userInfo().username }) + }, + toResubmitClick() { + let _this = this + if (this.selectedRowKeys.length == 0) { + this.$message.warning(this.$t('selectLeastOne')) + } else if (this.selectedRowKeys.length > 1) { + this.$message.warning(this.$t('OnlyOneSelected')) + } else if (this.selectedRowKeys.length == 1) { + let dataSource = [] + for (let i = 0; i < this.dataSource.length; i++) { + for (let j = 0; j < this.selectedRowKeys.length; j++) { + if (this.dataSource[i].id == this.selectedRowKeys[j]) { + dataSource.push(this.dataSource[i]) + } + } + } + let isDesign = false + let isVerify = false + if (dataSource[0].designFlowStatus == 'Compliance') { + isDesign = true + } + if (dataSource[0].verifyFlowStatus == 'Compliance') { + isVerify = true + } + if (isDesign || isVerify) { + this.$refs.toResubmitFormRef.getData(dataSource[0], isDesign, isVerify) + } else { + this.$message.warning(this.$t('selectDesignConformanceAsConformance')) + } + } + }, + toResubmitFormForm() { + this.getList() } // profileClick() { // let _this = this @@ -3457,6 +3595,11 @@ .operator-text-title:last-child { margin-bottom: 0; } + + .noteConfirm { + font-size: 14px; + margin-bottom: 10px; + } \ No newline at end of file diff --git a/jero-web/src/views/toDoCenter/projectRegulationTasks/components/circulationHistory.vue b/jero-web/src/views/toDoCenter/projectRegulationTasks/components/circulationHistory.vue index 3528accfb..c06a8c737 100644 --- a/jero-web/src/views/toDoCenter/projectRegulationTasks/components/circulationHistory.vue +++ b/jero-web/src/views/toDoCenter/projectRegulationTasks/components/circulationHistory.vue @@ -42,14 +42,14 @@ -