diff --git a/app/view/component/flow/processFlow.html b/app/view/component/flow/processFlow.html
index 10f19c4..02f2391 100644
--- a/app/view/component/flow/processFlow.html
+++ b/app/view/component/flow/processFlow.html
@@ -303,7 +303,7 @@ Vue.component("process-flow", {
this.activeMenuIndex = event?.target.dataset.menuIndex
},
menuShown(index){
- return event?.target.dataset.itemIndex == this.activeMenuIndex || false
+ return event?.target.dataset?.itemIndex == this.activeMenuIndex || false
},
async addNodeBySimple({type, prevIndex = -1}){
@@ -829,6 +829,12 @@ Vue.component("process-flow", {
this.disPassValidateText += "只允许存在1个开始节点或结束节点!\n"
}
+ // 不允许没有审核节点
+ if(!nodeList.some(node => node.properties.type == 'approvalTask')){
+ this.isPassValidate = false
+ this.disPassValidateText += "不允许存在无审批人的审批流程!\n"
+ }
+
// 不允许孤立节点 => 除了开始节点和结束节点外,每个节点都有入线和出线
var lineBySourceNodeId = _.groupBy(lineList, 'sourceNodeId'),
lineByTargetNodeId = _.groupBy(lineList, 'targetNodeId'),
@@ -844,12 +850,12 @@ Vue.component("process-flow", {
// 判断开始节点是否只含有出线sourceNodeId
if(_.some(Object.keys(lineByTargetNodeId), (i) => i.startsWith('start-'))){
this.isPassValidate = false
- this.disPassValidateText += "连线终点不能为开始节点!"
+ this.disPassValidateText += "连线终点不能为开始节点!\n"
}
// 结束节点是否是含有入线targetNodeId
if(_.some(Object.keys(lineBySourceNodeId), (i) => i.startsWith('end-'))){
this.isPassValidate = false
- this.disPassValidateText += "连线起点不能为结束节点!"
+ this.disPassValidateText += "连线起点不能为结束节点!\n"
}
// 其他的节点必须至少有一个入线和出线
for (const key in mergeTemp) {
@@ -859,7 +865,7 @@ Vue.component("process-flow", {
if(!_.some(element, i => i.sourceNodeId == key) || !_.some(element, i => i.targetNodeId == key)){
this.isPassValidate = false
- this.disPassValidateText += "不允许存在除了开始和结束节点以外的节点没有入线或出线!"
+ this.disPassValidateText += "不允许存在除了开始和结束节点以外的节点没有入线或出线!\n"
break
}
}
@@ -877,12 +883,12 @@ Vue.component("process-flow", {
if(_.some(node, i => i.properties.type == "conditionTask")){
if(_.some(node, i => i.properties.type != "conditionTask")){
this.isPassValidate = false
- this.disPassValidateText += "不允许条件节点和审批/通知节点存在同一层级!"
+ this.disPassValidateText += "不允许条件节点和审批/通知节点存在同一层级!\n"
}
}else{
if(node.length > 1){
this.isPassValidate = false
- this.disPassValidateText += "不允许同一层级多个审批/抄送节点同时存在!"
+ this.disPassValidateText += "不允许同一层级多个审批/抄送节点同时存在!\n"
}
}
}
@@ -898,7 +904,7 @@ Vue.component("process-flow", {
if(!_.some(conditionNode, i => i.properties.priority == -1)){
this.isPassValidate = false
- this.disPassValidateText += "不允许存在某层条件节点没有默认条件优先级!"
+ this.disPassValidateText += "不允许存在某层条件节点没有默认条件优先级!\n"
}
}
}
@@ -910,31 +916,31 @@ Vue.component("process-flow", {
if(['conditionTask'].includes(element.properties.type)){
if(!element.properties.priority){
this.isPassValidate = false
- this.disPassValidateText += `${element.properties.label}节点没有设置优先级!`
+ this.disPassValidateText += `${element.properties.label}节点没有设置优先级!\n`
}else{
if(element.properties.priority != -1 && element.properties.conditionList.length <= 0){
this.isPassValidate = false
- this.disPassValidateText += `${element.properties.label}节点没有设置条件组!`
+ this.disPassValidateText += `${element.properties.label}节点没有设置条件组!\n`
}
}
}else if(['approvalTask'].includes(element.properties.type)){
if(!element.properties.approvalType || !element.properties.approverType){
this.isPassValidate = false
- this.disPassValidateText += `${element.properties.label}节点没有完善信息!`
+ this.disPassValidateText += `${element.properties.label}节点没有完善信息!\n`
}else if(element.properties.approverType != '申请人自选'){
if(!(element.properties.user && element.properties.user?.length > 0)){
this.isPassValidate = false
- this.disPassValidateText += `${element.properties.label}节点没有完善信息!`
+ this.disPassValidateText += `${element.properties.label}节点没有完善信息!\n`
}
}
}else if(['noticeTask'].includes(element.properties.type)){
if(!element.properties.noticerType){
this.isPassValidate = false
- this.disPassValidateText += `${element.properties.label}节点没有完善信息!`
+ this.disPassValidateText += `${element.properties.label}节点没有完善信息!\n`
}else if(element.properties.noticerType != '申请人自选'){
if(!(element.properties.user && element.properties.user?.length > 0)){
this.isPassValidate = false
- this.disPassValidateText += `${element.properties.label}节点没有完善信息!`
+ this.disPassValidateText += `${element.properties.label}节点没有完善信息!\n`
}
}
}
diff --git a/app/view/page/workflowManagement.html b/app/view/page/workflowManagement.html
index 5ed8eff..fe71ed5 100644
--- a/app/view/page/workflowManagement.html
+++ b/app/view/page/workflowManagement.html
@@ -56,8 +56,8 @@
mdi-note-edit-outline编辑
-
- mdi-note-edit-outline删除
+
+ mdi-note-edit-outline删除