fix DAG environment list error (#6551)

This commit is contained in:
wangyizhi 2021-10-16 22:45:55 +08:00 committed by GitHub
parent de61d65af2
commit 4d0869fcc0
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -109,17 +109,10 @@
}
},
created () {
let stateEnvironmentList = this.store.state.security.environmentListAll || []
if (stateEnvironmentList.length && stateEnvironmentList.length > 0) {
this.environmentList = stateEnvironmentList
this._getEnvironmentAll().then(res => {
this.environmentList = res
this._initEnvironmentOptions(this.workerGroup)
} else {
this._getEnvironmentAll().then(res => {
this.environmentList = res
this._initEnvironmentOptions(this.workerGroup)
})
}
})
}
}
</script>