From c4657055f09e529b4e71814c34d62615d97d7f08 Mon Sep 17 00:00:00 2001
From: chenyc <501753378@qq.com>
Date: 星期五, 15 七月 2022 21:59:20 +0800
Subject: [PATCH] up

---
 src/samples/sockteStomp.ts |   31 ++++++++++++++-----------------
 1 files changed, 14 insertions(+), 17 deletions(-)

diff --git a/src/samples/sockteStomp.ts b/src/samples/sockteStomp.ts
index 0a04b93..98ce952 100644
--- a/src/samples/sockteStomp.ts
+++ b/src/samples/sockteStomp.ts
@@ -176,27 +176,24 @@
         stompClient.send(`/app/workstation/config/set/${clientCode}/${pcName}`,{},JSON.stringify({"clientCode":clientCode,"machineName":pcName}))
         
     }
-<<<<<<< HEAD
     // 更新sockte链接状态
     sockteStore().setsockteIsLink(true)
     console.log(sockteStore().isLink)
     if(devices!==undefined&&devices.length>0){
-=======
-    
-    // 更新sockte链接状态
-    sockteStore().setsockteIsLink(true)
-    console.log(sockteStore().isLink)
-    console.log(devices)
-    if(devices!==undefined&&devices!=null &&devices.length>0){
->>>>>>> 5fc7472d0ec6bff69b874f33eeccc30541f7f6df
-        devices.forEach(de=>{
-            if(stompClient!==null){
-                stompClient.subscribe(`/queue/${clientCode}/${de.deviceName}/result`,callback)
-                // stompClient.subscribe(`/queue/${clientCode}/${de.deviceName}/keepalive`,callbackState)
-                stompClient.send(`/app/device/request/${clientCode}/${de.deviceName}`, {}, JSON.stringify({"deviceNumber":de.deviceName}));
+        // 更新sockte链接状态
+        sockteStore().setsockteIsLink(true)
+        console.log(sockteStore().isLink)
+        console.log(devices)
+        if(devices!==undefined&&devices!=null &&devices.length>0){
+            devices.forEach(de=>{
+                if(stompClient!==null){
+                    stompClient.subscribe(`/queue/${clientCode}/${de.deviceName}/result`,callback)
+                    // stompClient.subscribe(`/queue/${clientCode}/${de.deviceName}/keepalive`,callbackState)
+                    stompClient.send(`/app/device/request/${clientCode}/${de.deviceName}`, {}, JSON.stringify({"deviceNumber":de.deviceName}));
 
-            } 
-        })
+                } 
+            })
+        }
     }
 }
 
@@ -212,7 +209,7 @@
         stompClient?.disconnect(disconnectCallBack,{})
         stompClient = Stomp.over(socket)
         stompClient.connect({}, connectCallback,error_callback)
-    },10000)
+    },60000)
 }
 // 创建客户端链接
 const creatorClient=(devices2:any,clientCode2:any)=>{

--
Gitblit v1.8.0