Skip to content

Commit

Permalink
[bugFix][ui] cherry pick commit from dev for When modifying the dag, …
Browse files Browse the repository at this point in the history
…if the DAG is not saved, it cannot be formatted (#3282)

* Click Cancel, the node data is restored to the original data

* Delete the pid of the master and worker processes

* When modifying the dag, if the DAG is not saved, it cannot be formatted
  • Loading branch information
break60 committed Jul 23, 2020
1 parent 86c4f7a commit f668563
Show file tree
Hide file tree
Showing 4 changed files with 9 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -170,6 +170,10 @@
// DAG automatic layout
dagAutomaticLayout() {
if(this.store.state.dag.isEditDag) {
this.$message.warning(`${i18n.$t('Please save the DAG before formatting')}`)
return false
}
$('#canvas').html('')
// Destroy round robin
Expand Down
1 change: 1 addition & 0 deletions dolphinscheduler-ui/src/js/conf/home/store/dag/actions.js
Original file line number Diff line number Diff line change
Expand Up @@ -230,6 +230,7 @@ export default {
id: payload
}, res => {
resolve(res)
state.isEditDag = false
}).catch(e => {
reject(e)
})
Expand Down
3 changes: 2 additions & 1 deletion dolphinscheduler-ui/src/js/module/i18n/locale/en_US.js
Original file line number Diff line number Diff line change
Expand Up @@ -599,5 +599,6 @@ export default {
zkDirectory: 'zkDirectory',
'Directory detail': 'Directory detail',
'Connection name': 'Connection name',
'Current connection settings': 'Current connection settings'
'Current connection settings': 'Current connection settings',
'Please save the DAG before formatting': 'Please save the DAG before formatting'
}
3 changes: 2 additions & 1 deletion dolphinscheduler-ui/src/js/module/i18n/locale/zh_CN.js
Original file line number Diff line number Diff line change
Expand Up @@ -604,5 +604,6 @@ export default {
zkDirectory: 'zk注册目录',
'Directory detail': '查看目录详情',
'Connection name': '连线名',
'Current connection settings': '当前连线设置'
'Current connection settings': '当前连线设置',
'Please save the DAG before formatting': '格式化前请先保存DAG'
}

0 comments on commit f668563

Please sign in to comment.