From 1bd03f5c2e7b9fa9cc80c4e673e18132da411333 Mon Sep 17 00:00:00 2001
From: jhzh <1628036192@qq.com>
Date: Wed, 12 Nov 2025 16:21:06 +0800
Subject: [PATCH] 1

---
 src/components/stock-list.vue |   17 +++++++++++++++--
 1 files changed, 15 insertions(+), 2 deletions(-)

diff --git a/src/components/stock-list.vue b/src/components/stock-list.vue
index 6eac297..4dd0849 100644
--- a/src/components/stock-list.vue
+++ b/src/components/stock-list.vue
@@ -74,9 +74,22 @@
   watch: {},
   mounted() {
     this.init();
-    this.initWebSocket();
+    this.getExchange()
   },
   methods: {
+    async getExchange(){
+      let data = await api.getExchange();
+      if (data.status === 0) {
+        // Toast.success(data.msg);
+        if(data.data==false){
+
+        }else{
+          this.initWebSocket();
+        }
+      } else {
+        Toast.fail(data.msg);
+      }
+    },
     init() {
       this.pageNum = 1;
       this.stockList = [];
@@ -140,7 +153,7 @@
     initWebSocket() {
       console.log("initWebSocket");
       this.Trade = new WhrWebSocket({
-        path: `wss://usws.yanshiz.com/websocket-server `,
+        path: `wss://ws.jinmanxuan.com/websocket-server `,
         onmessage: this.getTradeMessage
       });
 

--
Gitblit v1.9.3