This commit is contained in:
parent
447382eefe
commit
9e09a4ba84
|
|
@ -78,7 +78,7 @@ export default {
|
|||
]
|
||||
},
|
||||
socket: null,
|
||||
wsUrl: JSON.parse(localStorage.getItem('systemConfig')).webSocketurl,//'ws://localhost:18082/ws', // WebSocket 端点
|
||||
wsUrl: '',//'ws://localhost:18082/ws', // WebSocket 端点
|
||||
isConnected: false, // 连接状态
|
||||
reconnectInterval: 5000 // 自动重连时间间隔(毫秒
|
||||
|
||||
|
|
@ -117,6 +117,8 @@ export default {
|
|||
},
|
||||
created() {
|
||||
// this.checkPasswordStatus()
|
||||
const systemConfig = localStorage.getItem('systemConfig')
|
||||
this.wsUrl = systemConfig ? JSON.parse(systemConfig).webSocketurl : ''
|
||||
if (this.roles.includes("audit") || this.roles.includes("systemAdmin")) {
|
||||
this.connectWebSocket();
|
||||
}
|
||||
|
|
|
|||
Loading…
Reference in New Issue