From eed6e52aed587531444c5b51fc55b4f5c6d31b2e Mon Sep 17 00:00:00 2001
From: Junjie <540245094@qq.com>
Date: 星期二, 09 一月 2024 16:56:32 +0800
Subject: [PATCH] #

---
 src/main/webapp/views/shuttle2.html |   12 +++++++++---
 1 files changed, 9 insertions(+), 3 deletions(-)

diff --git a/src/main/webapp/views/shuttle2.html b/src/main/webapp/views/shuttle2.html
index c1cdc91..85470c4 100644
--- a/src/main/webapp/views/shuttle2.html
+++ b/src/main/webapp/views/shuttle2.html
@@ -257,7 +257,7 @@
 
     //濡傛灉鍑虹幇杩炴帴銆佸鐞嗐�佹帴鏀躲�佸彂閫佹暟鎹け璐ョ殑鏃跺�欒Е鍙憃nerror浜嬩欢
     ws.onerror = function(e) {
-        console.log(error);
+        console.log(e);
     }
 
     $(document).ready(function() {
@@ -347,7 +347,10 @@
 
     // 鍥涘悜绌挎杞︿俊鎭〃鑾峰彇 ---- 琛ㄤ竴
     function getShuttleStateInfo() {
-        sendWs("{\"url\":\"/shuttle/table/shuttle/state\",\"data\":{}}")
+        sendWs(JSON.stringify({
+            "url": "/shuttle/table/shuttle/state",
+            "data": {}
+        }))
     }
 
     // 鍥涘悜绌挎杞︿俊鎭〃璁剧疆 ---- 琛ㄤ竴
@@ -426,7 +429,10 @@
 
     // 绌挎杞︽棩蹇楄緭鍑� -----------------------------------------------------------------------
     function getShuttleOutput() {
-        sendWs("{\"url\":\"/shuttle/output/shuttle\",\"data\":{}}")
+        sendWs(JSON.stringify({
+            "url": "/shuttle/output/shuttle",
+            "data": {}
+        }))
     }
 
     function setShuttleOutput(res) {

--
Gitblit v1.9.1