feat: 流程审批,预测下个节点是否需要选择审批人

This commit is contained in:
lizhixian
2025-02-25 17:01:26 +08:00
parent de35fd0a7c
commit b346545cbf
4 changed files with 85 additions and 32 deletions

View File

@ -157,25 +157,24 @@ const initProcessInfo = async (row: any, formVariables?: any) => {
}
/** 预测流程节点会因为输入的参数值而产生新的预测结果值,所以需重新预测一次 */
// TODO @芋艿:这里我执行填写表单的时候不知道为啥一直报错,先注释了 @lesan可以和群里的小北说下
// watch(
// detailForm.value,
// (newValue) => {
// if (newValue && Object.keys(newValue.value).length > 0) {
// // 记录之前的节点审批人
// tempStartUserSelectAssignees.value = startUserSelectAssignees.value
// startUserSelectAssignees.value = {}
// // 加载最新的审批详情
// getApprovalDetail({
// id: props.selectProcessDefinition.id,
// processVariablesStr: JSON.stringify(newValue.value) // 解决 GET 无法传递对象的问题,后端 String 再转 JSON
// })
// }
// },
// {
// immediate: true
// }
// )
watch(
detailForm.value,
(newValue) => {
if (newValue && Object.keys(newValue.value).length > 0) {
// 记录之前的节点审批人
tempStartUserSelectAssignees.value = startUserSelectAssignees.value
startUserSelectAssignees.value = {}
// 加载最新的审批详情
getApprovalDetail({
id: props.selectProcessDefinition.id,
processVariablesStr: newValue.value // 解决 GET 无法传递对象的问题,后端 String 再转 JSON
})
}
},
{
immediate: true
}
)
/** 获取审批详情 */
const getApprovalDetail = async (row: any) => {