From c3e20747cfc00f4ebbeb5ac3531953c9a4083c4c Mon Sep 17 00:00:00 2001
From: haoxuan <haoxuan>
Date: 星期四, 21 九月 2023 15:00:35 +0800
Subject: [PATCH] 修改bug 无数据页面的显示问题

---
 src/views/visualization.vue |   16 ++++++++--------
 1 files changed, 8 insertions(+), 8 deletions(-)

diff --git a/src/views/visualization.vue b/src/views/visualization.vue
index 4ca6d69..aab6145 100644
--- a/src/views/visualization.vue
+++ b/src/views/visualization.vue
@@ -862,6 +862,14 @@
           this.Tasks = res.data.Tasks ? res.data.Tasks : [];
           
           this.TaskCount=res.data.TaskCount?res.data.TaskCount:0
+          if (this.Tasks.length == 0&&this.TaskCount==0) {
+            if (this.activeName == 1) {
+              this.Tasks.push(object);
+            } else {
+              this.Tasks.push(object);
+              this.Tasks.push(object);
+            }
+          }
           this.workers=res.data.workers?res.data.workers:[]
           for (let i in this.Tasks) {
             this.Tasks[i].procedureList = [];
@@ -903,14 +911,6 @@
                 }, 3000);
           }
         }
-          if (this.Tasks.length == 0) {
-            if (this.activeName == 1) {
-              this.Tasks.push(object);
-            } else {
-              this.Tasks.push(object);
-              this.Tasks.push(object);
-            }
-          }
         if (res.code != 200 || this.Tasks.length == 0) {
           this.getcountdown();
           // 鎺у埗閲嶆柊璇锋眰getTaskInfo, 鍙紑鍚竴涓畾鏃跺櫒

--
Gitblit v1.8.0