|
|
@ -54,7 +54,6 @@ const JSP = function () { |
|
|
|
isClick: false |
|
|
|
isClick: false |
|
|
|
} |
|
|
|
} |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
/** |
|
|
|
/** |
|
|
|
* dag init |
|
|
|
* dag init |
|
|
|
*/ |
|
|
|
*/ |
|
|
@ -199,7 +198,9 @@ JSP.prototype.jsonHandle = function ({ largeJson, locations }) { |
|
|
|
isAttachment: this.config.isAttachment, |
|
|
|
isAttachment: this.config.isAttachment, |
|
|
|
taskType: v.type, |
|
|
|
taskType: v.type, |
|
|
|
runFlag: v.runFlag, |
|
|
|
runFlag: v.runFlag, |
|
|
|
nodenumber: locations[v.id].nodenumber |
|
|
|
nodenumber: locations[v.id].nodenumber, |
|
|
|
|
|
|
|
successNode: v.conditionResult.successNode[0], |
|
|
|
|
|
|
|
failedNode: v.conditionResult.failedNode[0] |
|
|
|
})) |
|
|
|
})) |
|
|
|
|
|
|
|
|
|
|
|
// contextmenu event
|
|
|
|
// contextmenu event
|
|
|
@ -746,12 +747,28 @@ JSP.prototype.jspBackfill = function ({ connects, locations, largeJson }) { |
|
|
|
targetId = v.endPointTargetId |
|
|
|
targetId = v.endPointTargetId |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
if($(`#${sourceId}`).attr('data-tasks-type') === 'CONDITIONS' && $(`#${sourceId}`).attr('data-successnode') === $(`#${targetId}`).find('.name-p').text()) { |
|
|
|
|
|
|
|
this.JspInstance.connect({ |
|
|
|
|
|
|
|
source: sourceId, |
|
|
|
|
|
|
|
target: targetId, |
|
|
|
|
|
|
|
type: 'basic', |
|
|
|
|
|
|
|
paintStyle: { strokeWidth: 2, stroke: '#4caf50' } |
|
|
|
|
|
|
|
}) |
|
|
|
|
|
|
|
} else if($(`#${sourceId}`).attr('data-tasks-type') === 'CONDITIONS' && $(`#${sourceId}`).attr('data-failednode') === $(`#${targetId}`).find('.name-p').text()) { |
|
|
|
|
|
|
|
this.JspInstance.connect({ |
|
|
|
|
|
|
|
source: sourceId, |
|
|
|
|
|
|
|
target: targetId, |
|
|
|
|
|
|
|
type: 'basic', |
|
|
|
|
|
|
|
paintStyle: { strokeWidth: 2, stroke: '#f14343' } |
|
|
|
|
|
|
|
}) |
|
|
|
|
|
|
|
} else { |
|
|
|
this.JspInstance.connect({ |
|
|
|
this.JspInstance.connect({ |
|
|
|
source: sourceId, |
|
|
|
source: sourceId, |
|
|
|
target: targetId, |
|
|
|
target: targetId, |
|
|
|
type: 'basic', |
|
|
|
type: 'basic', |
|
|
|
paintStyle: { strokeWidth: 2, stroke: '#2d8cf0' } |
|
|
|
paintStyle: { strokeWidth: 2, stroke: '#2d8cf0' } |
|
|
|
}) |
|
|
|
}) |
|
|
|
|
|
|
|
} |
|
|
|
}) |
|
|
|
}) |
|
|
|
}) |
|
|
|
}) |
|
|
|
|
|
|
|
|
|
|
|