NEZ-2400 fix:登录失败 显示错误提示,不关闭弹窗,用户修改后可再次点击登录

This commit is contained in:
zhangyu
2022-11-25 18:49:17 +08:00
parent c1354269a8
commit ac6d0bacb1
3 changed files with 20 additions and 2 deletions

View File

@@ -203,6 +203,8 @@ export default {
this.terminal.uuid = res.data.uuid
this.userName = res.data.authUsername + '@' + res.data.host
this.host = res.data.host
params.name = this.terminal.name
this.$emit('loginFail', params)
this.$message.error(res.msg)
}
})

View File

@@ -46,6 +46,7 @@
:isFullScreen="isFullScreen"
:ref="'console'+index"
:terminal="item.terminal"
@loginFail="loginFail"
@closeConsole="removeTab"
@refreshConsoleTitle="refreshTabTitle"
></my-console>
@@ -647,9 +648,24 @@ export default {
this.$store.commit('removeConsole')
if (this.editableTabs.length <= 0) {
this.closeConsole()
// this.closeConsole()
}
},
loginFail (params) {
this.removeTab(params.name)
setTimeout(() => {
if (params.assetId) {
this.assetShowChange()
} else {
console.log()
this.customConnect = {
authType: Number(params.authType),
...params
}
this.customShow = true
}
})
},
/* 活动标签切换时触发 */
beforeLeave (currentName, oldName) {
// 重点如果name是add则什么都不触发

File diff suppressed because one or more lines are too long