FengChaoYu 3 лет назад
Родитель
Сommit
3336725232
1 измененных файлов с 1 добавлено и 1 удалено
  1. 1 1
      src/layout/components/Navbar.vue

+ 1 - 1
src/layout/components/Navbar.vue

@@ -380,7 +380,7 @@ export default {
       // WebSocket与普通的请求所用协议有所不同,ws等同于http,wss等同于https
       var userId = this.$store.getters.userid;
 
-      var url = process.env.VUE_APP_BASE_API.replace("https://","wss://").replace("http://","ws://")+"websocket/"+userId;
+      var url = process.env.VUE_APP_BASE_API.replace("https://","wss://").replace("http://","ws://").replace("api","supply")+"websocket/"+userId;
       console.debug(userId, url);
       let token = getToken()
       this.websock = new WebSocket(url, [token]);