NEZ-2505 fix:发送文本到所有窗口bug
This commit is contained in:
@@ -276,8 +276,8 @@ export default {
|
||||
},
|
||||
enterStr (message) {
|
||||
if (this.terminalSocket && this.terminal.isLogin) {
|
||||
this.terminalSocket.send(message)
|
||||
this.terminalSocket.send('\n')
|
||||
this.term.send(message)
|
||||
this.term.send('\n')
|
||||
this.term.scrollToBottom()
|
||||
this.historyChange(message)
|
||||
}
|
||||
|
||||
@@ -94,10 +94,10 @@ export default {
|
||||
const data = JSON.parse(e.data)
|
||||
self.$get('asset/asset/' + data.id).then(res => {
|
||||
const asset = res.data
|
||||
self.$refs.websshNew.addConsole(asset.id, asset.manageIp, '', '', 'asset')
|
||||
self.$refs.websshNew.addConsole(asset.id, asset.manageIp, '', '', 'asset', asset)
|
||||
})
|
||||
} catch (e) {
|
||||
// console.log(e)
|
||||
console.log(e)
|
||||
}
|
||||
}
|
||||
})
|
||||
|
||||
@@ -654,7 +654,7 @@ export default {
|
||||
terminal.userName = res.data.authUsername + '@' + res.data.host
|
||||
terminal.host = res.data.host
|
||||
if (id) {
|
||||
console.terminal.terminalType = asset.type.authProtocol
|
||||
console.terminal.terminalType = asset ? asset.type.authProtocol : console.terminal.terminalType
|
||||
console.terminal.username = ''
|
||||
this.editableTabsValue = newTabName
|
||||
this.editableTabs.push(console)
|
||||
@@ -689,7 +689,7 @@ export default {
|
||||
console.name = newTabName
|
||||
console.terminal.name = newTabName
|
||||
console.terminal.isLogin = false
|
||||
this.editableTabs.push(console)
|
||||
this.addConsole(item.terminal.assetId, item.terminal.host, '', '', 'asset')
|
||||
} else {
|
||||
this.customConnect = {
|
||||
...item.terminal.custom,
|
||||
|
||||
Reference in New Issue
Block a user