From 042b28b2d62860db912b254420fb4172880aafab Mon Sep 17 00:00:00 2001
From: 648540858 <648540858@qq.com>
Date: 星期一, 22 八月 2022 16:17:28 +0800
Subject: [PATCH] 支持全局异常和统一返回结果

---
 web_src/src/components/dialog/chooseChannelForStream.vue |   16 +++++++++-------
 1 files changed, 9 insertions(+), 7 deletions(-)

diff --git a/web_src/src/components/dialog/chooseChannelForStream.vue b/web_src/src/components/dialog/chooseChannelForStream.vue
index 1eec0b2..8d63dbf 100644
--- a/web_src/src/components/dialog/chooseChannelForStream.vue
+++ b/web_src/src/components/dialog/chooseChannelForStream.vue
@@ -180,15 +180,17 @@
                 }
                 })
                 .then(function (res) {
-                    that.total = res.data.total;
-                    that.gbStreams = res.data.list;
-                    that.gbChoosechannel = {};
-                    // 闃叉鍑虹幇琛ㄦ牸閿欎綅
-                    that.$nextTick(() => {
+                    if (res.data.code === 0) {
+                      that.total = res.data.data.total;
+                      that.gbStreams = res.data.data.list;
+                      that.gbChoosechannel = {};
+                      // 闃叉鍑虹幇琛ㄦ牸閿欎綅
+                      that.$nextTick(() => {
                         that.$refs.gbStreamsTable.doLayout();
                         // 榛樿閫変腑
-                         that.eventEnable = true;
-                    })
+                        that.eventEnable = true;
+                      })
+                    }
                 })
                 .catch(function (error) {
                     console.log(error);

--
Gitblit v1.8.0