From 92ac16fad20cbd4c0035501ef04605bdb960fc18 Mon Sep 17 00:00:00 2001
From: zjj <3272660260@qq.com>
Date: 星期五, 24 五月 2024 10:36:49 +0800
Subject: [PATCH] #提升机状态

---
 src/main/webapp/views/realtimeWatch/console.html |   23 +++++++++++++++++++++++
 1 files changed, 23 insertions(+), 0 deletions(-)

diff --git a/src/main/webapp/views/realtimeWatch/console.html b/src/main/webapp/views/realtimeWatch/console.html
index b6ff3e7..3752f0b 100644
--- a/src/main/webapp/views/realtimeWatch/console.html
+++ b/src/main/webapp/views/realtimeWatch/console.html
@@ -503,6 +503,7 @@
     // 鍒濆鍖�
     getSitesInfo();
     getCrnInfo();
+    getHoistInfo();
     getSystemRunningStatus();
     getBarcodeInfo();
     getScaleInfo();
@@ -515,6 +516,7 @@
     }, 1000);
     setInterval(function () {
         getSitesInfo();
+        getHoistInfo();
     }, 3000);
 
     // 绯荤粺杩愯寮�鍏�
@@ -664,6 +666,27 @@
     }
 
     // 鎵爜鍣ㄥ疄鏃舵暟鎹幏鍙�
+    function getHoistInfo() {
+        $.ajax({
+            url: baseUrl + "/console/latest/data/hoist",
+            headers: {'token': localStorage.getItem('token')},
+            method: 'POST',
+            success: function (res) {
+                if (res.code === 200) {
+                    var hoists = res.data;
+                    for (var i = 0; i < hoists.length; i++) {
+                        $("#hoist-"+hoists[i].hoistId).html(hoists[i].place ? hoists[i].place : "--");
+                    }
+                } else if (res.code === 403) {
+                    parent.location.href = baseUrl + "/login";
+                } else {
+                    console.log(res.msg);
+                }
+            }
+        });
+    }
+
+    // 鎵爜鍣ㄥ疄鏃舵暟鎹幏鍙�
     function getBarcodeInfo() {
         $.ajax({
             url: baseUrl + "/console/latest/data/barcode",

--
Gitblit v1.9.1