|
@@ -2,8 +2,6 @@ import {ElMessageBox} from 'element-plus'
|
|
|
import Cookies from 'js-cookie'
|
|
|
import router from '@/router'
|
|
|
import store from '@/store'
|
|
|
-import SoctetDialog from "@/components/xiao-chan/websocket/SoctetDialog.vue";
|
|
|
-import {createApp} from 'vue'
|
|
|
|
|
|
const socketUrl = import.meta.env.VITE_SOCKET_URL
|
|
|
|
|
@@ -56,7 +54,8 @@ export function initWebSocket(sid, force) {
|
|
|
|
|
|
webSocket.onopen = function () {
|
|
|
socketErrDialog.value = false
|
|
|
- console.log('WebSocket连接成功')
|
|
|
+ store.commit('sidChange', sid)
|
|
|
+ console.log('WebSocket连接成功', sid)
|
|
|
}
|
|
|
|
|
|
webSocket.onmessage = function (e) {
|