| | |
| | | { name: "white", color: "#fff" }, |
| | | ]); |
| | | const links = ref([ |
| | | { text: "个人ä¸å¿", path: "/UserInfo", id: -1, icon: "el-icon-s-custom" }, |
| | | // { text: "个人ä¸å¿", path: "/UserInfo", id: -1, icon: "el-icon-s-custom" }, |
| | | { |
| | | text: "å®å
¨éåº", |
| | | path: "/login", |
| | |
| | | const createSocket = (url) => { |
| | | // å建WebSocketè¿æ¥ |
| | | //"ws://127.0.0.1:9295/admin" |
| | | client = new WebSocket(url); |
| | | // client = new WebSocket(url); |
| | | |
| | | client.onopen = function () { |
| | | client.onmessage = handleMessage; |
| | | store.commit("setWebsocket", client); |
| | | console.log("WebSocket è¿æ¥æå"); |
| | | }; |
| | | // client.onopen = function () { |
| | | // client.onmessage = handleMessage; |
| | | // store.commit("setWebsocket", client); |
| | | // console.log("WebSocket è¿æ¥æå"); |
| | | // }; |
| | | |
| | | client.onclose = function () { |
| | | console.log("WebSocket è¿æ¥å
³é"); |
| | | setTimeout(createSocket, 10000); |
| | | }; |
| | | // client.onclose = function () { |
| | | // console.log("WebSocket è¿æ¥å
³é"); |
| | | // setTimeout(createSocket, 10000); |
| | | // }; |
| | | |
| | | client.onerror = function () {}; |
| | | // client.onerror = function () {}; |
| | | }; |
| | | |
| | | const changeTheme = (name) => { |