优化流程标题

This commit is contained in:
huangxing123
2024-08-31 14:57:03 +08:00
parent 899bd0366e
commit 150b109af0
2 changed files with 9 additions and 19 deletions

View File

@@ -216,19 +216,14 @@ public class WfProcessServiceImpl extends FlowServiceFactory implements IWfProce
// 查询任务节点参数并转换成Map目的是获取流程标题(新增于2024年2月29日) // 查询任务节点参数并转换成Map目的是获取流程标题(新增于2024年2月29日)
List<HistoricVariableInstance> collectors = historyService.createHistoricVariableInstanceQuery().processInstanceId(hisIns.getId()).list(); List<HistoricVariableInstance> collectors = historyService.createHistoricVariableInstanceQuery().processInstanceId(hisIns.getId()).list();
if(CollUtil.isNotEmpty(collectors)){ if(CollUtil.isNotEmpty(collectors)){
taskVo.setProcVars(collectors.stream().collect(Collectors.toMap(HistoricVariableInstance::getVariableName, HistoricVariableInstance::getValue))); // taskVo.setProcVars(collectors.stream().collect(Collectors.toMap(HistoricVariableInstance::getVariableName, HistoricVariableInstance::getValue)));
// 遍历表单属性并获取值
collectors.stream().forEach(historicVariableInstance -> {
if (historicVariableInstance.getVariableName().equals("description")) {
taskVo.setProcVars(historicVariableInstance.getValue());
}
});
} }
/* Map<String, Object> collectors = historyService.createHistoricVariableInstanceQuery()
.processInstanceId(hisIns.getId())
.list()
.stream()
.collect(Collectors.toMap(HistoricVariableInstance::getVariableName, HistoricVariableInstance::getValue));
taskVo.setProcVars(collectors);*/
/* List<HistoricVariableInstance> list = historyService.createHistoricVariableInstanceQuery()
.processInstanceId(hisIns.getId())
.list();
taskVo.setProcVars(list);*/
taskVoList.add(taskVo); taskVoList.add(taskVo);
} }
page.setRecords(taskVoList); page.setRecords(taskVoList);

View File

@@ -206,16 +206,11 @@ export default {
this.loading = true; this.loading = true;
listOwnProcess(this.addDateRange(this.queryParams, this.dateRange)).then(response => { listOwnProcess(this.addDateRange(this.queryParams, this.dateRange)).then(response => {
// console.log(5555,response.rows) // console.log(5555,response.rows)
// this.ownProcessList = response.rows; this.ownProcessList = response.rows;
if(this.queryParams.description != null){
this.ownProcessList = this.searchList(response.rows, this.queryParams.description);
}else {
this.ownProcessList =response.rows;
}
this.total = response.total; this.total = response.total;
this.loading = false; this.loading = false;
}).catch((err) => { }).catch((err) => {
console.log(4444,err) // console.log(4444,err)
}); });
}, },