wang_xy пре 2 година
родитељ
комит
5a256000d1
1 измењених фајлова са 6 додато и 2 уклоњено
  1. 6 2
      src/components/TVWall.vue

+ 6 - 2
src/components/TVWall.vue

@@ -481,7 +481,6 @@ export default {
     },
 
     create(tvListJson, bfArray) { // 调用创建控件接口
-      debugger
       let _this = this
       const params = [
         {
@@ -502,8 +501,13 @@ export default {
       ]
       this.setPos()
       this.customizeTree(tvListJson);
+      let length = tvListJson[0].treeLabels.length > 4 ? 5 : tvListJson[0].treeLabels.length;
+      const bfArray = [];
+      for (let i = 1; i < length; i++) {
+        bfArray.push({"channelId": tvListJson[0].treeLabels[i].labelCode})
+      }
       _this.ws.createCtrl(params);
-      _this.playRealMonitorVideo(bfArray);
+      _this.playRealMonitorVideo(bfArray)
     },
     playRealMonitorVideo(array) { // 自定义设备树自动播放指定通道编码视频
       const config = this.ws.config