Browse Source

[Bug] Dependent components cannot be justified and viewed (#14924)

* Dependent components cannot be justified and viewed (dependent components cannot be edited and viewed) #14865

* Dependent components cannot be justified and viewed (dependent components cannot be edited and viewed) #14865  Improve stability

---------

Co-authored-by: AmriStrong <wanggang1@baseus.com>
Co-authored-by: xiangzihao <460888207@qq.com>
3.2.1-prepare
AmriStrong 1 year ago committed by GitHub
parent
commit
c438d7194c
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
  1. 4
      dolphinscheduler-ui/src/views/projects/task/components/node/fields/use-dependent.ts
  2. 7
      dolphinscheduler-ui/src/views/projects/workflow/components/dag/use-node-status.ts

4
dolphinscheduler-ui/src/views/projects/task/components/node/fields/use-dependent.ts

@ -258,8 +258,8 @@ export function useDependent(model: { [field: string]: any }): IJsonItem[] {
return null
const key = `${item.definitionCode}-${item.depTaskCode}-${item.cycle}-${item.dateValue}`
const state: ITaskState = dependentResult[key]
return h(NIcon, { size: 24, color: TasksStateConfig[state].color }, () =>
h(TasksStateConfig[state].icon)
return h(NIcon, { size: 24, color: TasksStateConfig[state]?.color }, () =>
h(TasksStateConfig[state]?.icon)
)
}

7
dolphinscheduler-ui/src/views/projects/workflow/components/dag/use-node-status.ts

@ -77,15 +77,14 @@ export function useNodeStatus(options: Options) {
window.$message.success(t('project.workflow.refresh_status_succeeded'))
taskList.value = res.taskList
if (taskList.value) {
const allDependentResult = {}
taskList.value.forEach((taskInstance: any) => {
setNodeStatus(taskInstance.taskCode, taskInstance.state, taskInstance)
if (taskInstance.dependentResult) {
nodeStore.updateDependentResult(
JSON.parse(taskInstance.dependentResult)
)
Object.assign(allDependentResult, JSON.parse(taskInstance.dependentResult))
}
})
nodeStore.updateDependentResult(allDependentResult)
}
})
}

Loading…
Cancel
Save