瀏覽代碼

新建分支,渲染方式调整

liuwei 4 年之前
父節點
當前提交
5302f2c771

+ 8 - 1
src/renderer/App.vue

@@ -33,15 +33,22 @@
           if(result[0].ID){
             console.log('上传设备配置文件成功!')
 
+            const windowJson = await getStaticFile('EnityWindow.Data')
+            const arr = windowJson.filter(item => item.IsVisibility === true)
+            const homeJson = arr[0]
+            console.log(homeJson)
+            this.$store.dispatch('updateHomeJson',homeJson)
+
+
             // 获取大屏,信号源,设备数据,label数据并保存到vuex中
             const bigScreenJson = await reqBigScreen()
             const signalListJson = await reqPreviewSourceList()
             const deviceJson = await reqDevice()
             const labelJson = await getStaticFile('EnityLable.Data')
+            this.$store.dispatch('updateLabelJson',labelJson)
             this.$store.dispatch('saveBigscreen',bigScreenJson.filter(item => item.IsVisibility === true))
             this.$store.dispatch('saveSignalList',signalListJson)
             this.$store.dispatch('saveDevice',deviceJson)
-            this.$store.dispatch('updateLabelJson',labelJson)
           }
         }
       })

+ 22 - 47
src/renderer/components/Admin.vue

@@ -4,35 +4,20 @@
         <!--主页-->
         <div :style="{
                     position: 'relative',
-                    left:windowJson[0] ? windowJson[0].Left*bigScale+'px' : '',
-                    top:windowJson[0] ? windowJson[0].Top*bigScale+'px' : '',
-                    width:windowJson[0] ? windowJson[0].Width*bigScale + 'px' : '',
-                    height:windowJson[0] ? windowJson[0].Height*bigScale + 'px' : '',
-                    zIndex:windowJson[0] ? windowJson[0].ZIndex : '',
-                    display:windowJson[0] ? (windowJson[0].IsVisibility ? 'block' : 'none') : '',
+                    left:homeJson ? homeJson.Left*bigScale+'px' : '',
+                    top:homeJson ? homeJson.Top*bigScale+'px' : '',
+                    width:homeJson ? homeJson.Width*bigScale + 'px' : '',
+                    height:homeJson ? homeJson.Height*bigScale + 'px' : '',
+                    zIndex:homeJson ? homeJson.ZIndex : '',
+                    display:homeJson ? (homeJson.IsVisibility ? 'block' : 'none') : '',
                     backgroundRepeat:'no-repeat',
                     backgroundSize:'100% 100%',
-                    backgroundColor:`#${windowJson[0] ? (windowJson[0].BrackgroupStr ? windowJson[0].BrackgroupStr.slice(3) : null) : ''}`,
+                    backgroundColor:`#${homeJson ? (homeJson.BrackgroupStr ? homeJson.BrackgroupStr.slice(3) : null) : ''}`,
                     margin:'0 auto'}"
              ref="mainpage"
         >
-            <!--按钮-->
-            <ButtonComponent />
-
-            <!--大屏显示-->
-            <BigShowComponent />
-
-            <!--label标签-->
-            <LabelComponent />
-
-            <!--图片-->
-            <ImageComponent />
-
-            <!--信号源列表-->
-            <SignalListComponent />
-
-            <!--滑块-->
-            <SliderComponent />
+            <Window />
+            <SignalList />
         </div>
 
         <!--最小化和关闭按钮-->
@@ -43,43 +28,33 @@
 
 <script>
     import {mapState} from 'vuex'
-    import storageUtils from "../../utils/storageUtils"
-    import '../assets/less/mainpage.less'
 
-    import ButtonComponent from './Button'
-    import LabelComponent from './Label'
-    import BigShowComponent from './BigShow'
-    import SignalListComponent from './SignalList'
-    import ImageComponent from './Image'
-    import SliderComponent from './Slider'
+    import '../assets/less/mainpage.less'
+    import storageUtils from "../../utils/storageUtils"
+    import Window from "./Window"
+    import SignalList from "./SignalList"
     import {getStaticFile} from "../../utils/tools"
 
     export default {
         components: {
-            ButtonComponent,
-            LabelComponent,
-            BigShowComponent,
-            SignalListComponent,
-            ImageComponent,
-            SliderComponent,
+            Window,
+            SignalList,
         },
 
         data() {
             return {
                 user: storageUtils.getUser(), // 本地存储的用户
-                windowJson:[], // 主窗口配置文件
-                staticUrl:this.$store.state.staticUrl
+                homeJson:{},
+                staticUrl:this.$store.state.staticUrl, // 静态资源路径
             }
         },
 
         async beforeCreate() {
-            const result = await getStaticFile('EnityWindow.Data')
-            this.windowJson = result.filter(item => item.IsVisibility === true)
-        },
-
-        updated() {
-            // 添加背景图片
-            this.$refs.mainpage.style.backgroundImage = this.windowJson[0].BackIcon ? 'url('+`${this.staticUrl}/Data/${this.windowJson[0].BackIcon}`+')' : null
+            const windowJson = await getStaticFile('EnityWindow.Data')
+            const arr = windowJson.filter(item => item.IsVisibility)
+            this.homeJson = arr[0]
+            // 主页添加背景图片
+            this.$refs.mainpage.style.backgroundImage = this.homeJson.BackIcon ? 'url('+`${this.staticUrl}/Data/${this.homeJson.BackIcon}`+')' : null
         },
 
         methods: {

+ 50 - 66
src/renderer/components/BigShow.vue

@@ -6,20 +6,23 @@
                 element="div"
                 v-model="signalPreList"
                 :options="dragOptions2"
-                :class="['split_screen', bigScreenObj[item.ID].splitStatus === 0 ? 'split_screen_one' : bigScreenObj[item.ID].splitStatus === 1 ? 'split_screen_four' : bigScreenObj[item.ID].splitStatus === 2 ? 'split_screen_nine' : 'split_screen_sixteen']"
+                :class="['split_screen',
+                bigScreenObj[item.ID] ?
+                bigScreenObj[item.ID].splitStatus === 0 ? 'split_screen_one' :
+                bigScreenObj[item.ID].splitStatus === 1 ? 'split_screen_four' :
+                bigScreenObj[item.ID].splitStatus === 2 ? 'split_screen_nine' : 'split_screen_sixteen' : '']"
                 :style="{
                     float:'left',
                     width:item.Width*bigScale + 'px',
                     height:item.Height*bigScale + 'px',
-                    left:item.Left*bigScale+'px',
-                    top:item.Top*bigScale+'px',
+                    left:(item.Left-window.Left)*bigScale+'px',
+                    top:(item.Top-window.Top)*bigScale+'px',
                     zIndex:item.ZIndex,
-                    display:item.IsVisibility ? 'black' : 'none',
                 }"
                 :id="item.ID"
         >
             <VueDragResize
-                    v-for="itemV in bigScreenObj[item.ID].signalArr" :key="itemV.Id" class="sitem"
+                    v-for="itemV in bigScreenObj[item.ID] ? bigScreenObj[item.ID].signalArr : []" :key="itemV.Id" class="sitem"
                     :w="itemV.width" :h="itemV.height" :parentLimitation="false"
                     :x="itemV.left" :y="itemV.top"
                     @dragstop="(position) => dragStop(position,itemV,bigScreenObj,curOpeBigscreenId)"
@@ -36,7 +39,7 @@
                 </div>
             </VueDragResize>
 
-            <div v-for="itemD in bigScreenObj[item.ID].bindList" class="sitem2">
+            <div v-for="itemD in bigScreenObj[item.ID] ? bigScreenObj[item.ID].bindList : []" class="sitem2">
                 {{itemD}}
             </div>
         </draggable>
@@ -47,7 +50,6 @@
     import {mapState} from 'vuex'
     import draggable from 'vuedraggable'
     import VueDragResize from 'vue-drag-resize'
-    import PubSub from 'pubsub-js'
 
     import '../assets/less/splitscreen.less'
     import {elePosition, getElementLeft, getElementTop, getStaticFile, guId} from "../../utils/tools"
@@ -80,6 +82,7 @@
                 screenPosition:{}, // 大屏在视口中的位置
                 videoPlayObj:{}, // 视频播放配置对象
                 savePreWh:{}, // 保存旧的开窗宽高
+                window:this.$attrs.window
             }
         },
 
@@ -90,55 +93,52 @@
         },
 
         async beforeCreate() {
-            /*this.updateCurrentBigScreen = PubSub.subscribe('updateCurrentBigScreen',(msg,data) => {
-                this.currentBigshow = data
-            })*/
-            
             // 加载大屏json文件
             const bigScreenJson = await getStaticFile('EnityBigScreen.Data')
             // 过滤出显示的大屏
-            this.currentBigshow = bigScreenJson.filter(item => item.IsVisibility === true)
+            this.currentBigshow = bigScreenJson.filter(item => item.WindowID === this.window.ID)
+            if(this.currentBigshow.length){
+                // 给大屏对象进行初始化显示
+                const obj = {}
+                this.currentBigshow.forEach(item => {
+                    obj[item.ID] = {
+                        bindList:[],
+                        splitStatus:0,
+                        signalArr:[],
+                        width:item.Width,
+                        height:item.Height
+                    }
+                    const num = item.BindList.filter(item => item.DeviceID).length
+                    // 拼接屏数量
+                    for(let i=0;i<num;i++){
+                        obj[item.ID].bindList.push(i+1)
+                    }
+                    // 根据拼接屏数量得到分屏状态
+                    obj[item.ID].splitStatus = Math.floor(Math.sqrt(num)-1)
+                })
+                this.$store.dispatch('updateBigscreenObj',obj)
 
-            // 给大屏对象进行初始化显示
-            const obj = {}
-            this.currentBigshow.forEach(item => {
-                obj[item.ID] = {
-                    bindList:[],
-                    splitStatus:0,
-                    signalArr:[],
-                    width:item.Width,
-                    height:item.Height
-                }
-                const num = item.BindList.length
-                // 拼接屏数量
-                for(let i=0;i<num;i++){
-                    obj[item.ID].bindList.push(i+1)
-                }
-                // 根据拼接屏数量得到分屏状态
-                obj[item.ID].splitStatus = Math.floor(Math.sqrt(num)-1)
-            })
-            this.$store.dispatch('updateBigscreenObj',obj)
-            
-            // 获取视频播放的配置对象
-            const preSingleList = await reqPreviewSourceList()
-            const videoPlayObj = {}
-            for(const item of preSingleList){
-                videoPlayObj[item.sourceId] = {
-                    sources: [
-                        {
-                            "src": item.previewUrl,
-                            "type": "rtmp/flv"
-                        }
-                    ],
-                    techOrder: ['flash'],
-                    autoplay: true,
-                    controls: false,
-                    fluid:true,
-                    preload: 'auto',
-                    notSupportedMessage: '此视频暂无法播放,请稍后再试',
+                // 获取视频播放的配置对象
+                const preSingleList = await reqPreviewSourceList()
+                const videoPlayObj = {}
+                for(const item of preSingleList){
+                    videoPlayObj[item.sourceId] = {
+                        sources: [
+                            {
+                                "src": item.previewUrl,
+                                "type": "rtmp/flv"
+                            }
+                        ],
+                        techOrder: ['flash'],
+                        autoplay: true,
+                        controls: false,
+                        fluid:true,
+                        preload: 'auto',
+                        notSupportedMessage: '此视频暂无法播放,请稍后再试',
+                    }
                 }
+                this.videoPlayObj = videoPlayObj
             }
-            this.videoPlayObj = videoPlayObj
         },
 
         updated() {
@@ -152,10 +152,6 @@
             })
         },
 
-        beforeDestroy() {
-            // PubSub.unsubscribe(this.updateCurrentBigScreen)
-        },
-
         methods: {
             // 大屏开窗接口提交
             async refreshBigScreen(obj,Id) {
@@ -293,17 +289,5 @@
                 return this.$refs.videoPlayer.player
             },
         },
-
-        watch: {
-            // 监视分屏的状态
-            /*splitScreenStatus: function(num) {
-                console.log(num)
-                this.$data.bindList = []
-                for (let i=0;i<(num+1)*(num+1);i++){
-                    this.$data.bindList.push(i+1)
-                }
-                this.rfreshBigScreen(this.$data.streamWindows)
-            }*/
-        }
     }
 </script>

+ 9 - 13
src/renderer/components/Button.vue

@@ -4,12 +4,11 @@
         <div v-for="item in buttonJson"
              :style="{
                     position:'absolute',
-                    left:item.Left*bigScale+'px',
-                    top:item.Top*bigScale+'px',
+                    left:(item.Left-window.Left)*bigScale+'px',
+                    top:(item.Top-window.Top)*bigScale+'px',
                     width:item.Width*bigScale + 'px',
                     height:item.Height*bigScale + 'px',
                     zIndex:item.ZIndex,
-                    display:item.IsVisibility ? 'block' : 'none',
                     fontSize:item.FontSize*bigScale + 'px',
                     backgroundSize:'100% 100%',
                     backgroundRepeat:'no-repeat',
@@ -36,21 +35,18 @@
     export default {
         data() {
             return {
-                buttonJson: [], // 所有按钮
-                slideJson: [], // 所有滑条
+                buttonJson: [], // 当前window中按钮
                 staticUrl:this.$store.state.staticUrl, // 静态资源路径
-                preBtns:[], // 上一次点击的按钮数组
+                window:this.$attrs.window
             }
         },
 
-        async mounted() {
-            this.buttonJson = await getStaticFile('EnityButton.Data')
-            this.slideJson = await getStaticFile('EnitySlider.Data')
-
-            // 初始化时默认按下的按钮
-            let preBtns = this.buttonJson.filter(item => (item.IsPressDown && item.IsVisibility))
-            this.preBtns = preBtns
+        async beforeCreate() {
+            const arr = await getStaticFile('EnityButton.Data')
+            this.buttonJson = arr.filter(item => item.WindowID === this.window.ID)
+        },
 
+        updated() {
             // 设置按钮背景图片
             const keyArr = Object.keys(this.$refs)
             keyArr.forEach((item,index) => {

+ 6 - 4
src/renderer/components/Image.vue

@@ -5,8 +5,8 @@
         <div v-for="item in imageJson"
              :style="{
                     position:'absolute',
-                    left:item.Left*bigScale+'px',
-                    top:item.Top*bigScale+'px',
+                    left:(item.Left-window.Left)*bigScale+'px',
+                    top:(item.Top-window.Top)*bigScale+'px',
                     width:item.Width*bigScale + 'px',
                     height:item.Height*bigScale + 'px',
                     zIndex:item.ZIndex,
@@ -28,12 +28,14 @@
         data() {
             return {
                 imageJson:[],
-                staticUrl:this.$store.state.staticUrl
+                staticUrl:this.$store.state.staticUrl,
+                window:this.$attrs.window
             }
         },
 
         async beforeCreate() {
-            this.imageJson = await getStaticFile('EnityImage.Data')
+            const arr = await getStaticFile('EnityImage.Data')
+            this.imageJson = arr.filter(item => item.WindowID === this.window.ID)
         },
 
         async updated() {

+ 17 - 4
src/renderer/components/Label.vue

@@ -5,14 +5,13 @@
         <div v-for="item in labelJson"
                :style="{
                  position:'absolute',
-                 left:item.Left*bigScale+'px',
-                 top:item.Top*bigScale+'px',
+                 left:(item.Left-window.Left)*bigScale+'px',
+                 top:(item.Top-window.Top)*bigScale+'px',
                  fontSize:item.FontSize*bigScale + 'px',
                  fontWeight:600,
                  width:item.Width*bigScale + 'px',
                  height:item.Height*bigScale + 'px',
                  zIndex:item.ZIndex,
-                 display:item.IsVisibility ? 'block' : 'none',
                  color:`#${item.ForegroundStr.slice(3)}`,
                  textAlign:'center',
                  lineHeight:item.Height*bigScale + 'px',
@@ -25,10 +24,24 @@
 
 <script>
     import {mapState} from 'vuex'
+    import {getStaticFile} from "../../utils/tools"
 
     export default {
+        data() {
+            return {
+                labelJson: [], // 当前window中按钮
+                staticUrl:this.$store.state.staticUrl, // 静态资源路径
+                window:this.$attrs.window
+            }
+        },
+
+        async beforeCreate() {
+            const arr = await getStaticFile('EnityLable.Data')
+            this.labelJson = arr.filter(item => item.WindowID === this.window.ID)
+        },
+
         computed: {
-            ...mapState(['bigScale','labelJson']),
+            ...mapState(['bigScale']),
         }
     }
 </script>

+ 0 - 5
src/renderer/components/SignalList.vue

@@ -71,11 +71,6 @@
         methods: {
             // 移动信号源
             onMove({relatedContext, draggedContext}) {
-                // 首先要知道拖拽到哪个大屏
-                // const bigscreenObj = this.$store.state.bigScreenObj
-                // let len = bigscreenObj[relatedContext.component.$el.id].signalArr.length
-                // let index = relatedContext.index ? relatedContext.index : 1
-                // const count = index-len > 0 ? index-len : 1
                 // 更新当前操作大屏ID
                 this.$store.dispatch('updateCurBigscreenId',relatedContext.component.$el.id)
 

+ 76 - 0
src/renderer/components/Window.vue

@@ -0,0 +1,76 @@
+<!--除主页意外的其他窗口-->
+<template>
+    <div>
+        <div v-for="item in windows"
+             :style="{
+                position: 'absolute',
+                left:item ? item.Left*bigScale+'px' : '',
+                top:item ? item.Top*bigScale+'px' : '',
+                width:item ? item.Width*bigScale + 'px' : '',
+                height:item ? item.Height*bigScale + 'px' : '',
+                zIndex:item ? item.ZIndex : '',
+                display:item ? (item.IsVisibility ? 'block' : 'none') : '',
+                backgroundRepeat:'no-repeat',
+                backgroundSize:'100% 100%',
+             }"
+                :ref="item.ID"
+        >
+            <Button :window="item"/>
+            <Label :window="item"/>
+            <Img :window="item"/>
+            <BigShow :window="item"/>
+        </div>
+    </div>
+</template>
+
+<script>
+    import {mapState} from "vuex"
+    import {getNeedMoutedEleArr, getStaticFile} from "../../utils/tools"
+    import Button from "./Button"
+    import Label from './Label'
+    import Img from './Image'
+    import BigShow from './BigShow'
+
+    export default {
+        components: {
+            Button,
+            Label,
+            Img,
+            BigShow
+        },
+
+        data() {
+            return {
+                windows:[],
+                eleObj:{},
+                staticUrl:this.$store.state.staticUrl, // 静态资源路径
+            }
+        },
+
+        async beforeCreate() {
+            const eleObj = {}
+            this.windows = await getStaticFile('EnityWindow.Data')
+            for(const item of this.windows){
+                eleObj[item.ID] = await getNeedMoutedEleArr(item.ID)
+            }
+            this.eleObj = eleObj
+        },
+
+        updated() {
+            // 设置背景图片
+            const keyArr = Object.keys(this.$refs)
+            keyArr.forEach(item => {
+                if(this.eleObj[item]){
+                    const arr = this.eleObj[item].filter(item => item.BackIcon)
+                    for(const a of arr){
+                        this.$refs[a.ID][0].style.backgroundImage = a.BackIcon ? 'url('+`${this.staticUrl}/Data/${a.BackIcon}`+')' : null
+                    }
+                }
+            })
+        },
+
+        computed: {
+            ...mapState(['bigScale'])
+        }
+    }
+</script>

+ 7 - 1
src/renderer/store/actions.js

@@ -14,7 +14,8 @@ import {
     SECOND_UPDATE_BIGSCREEN,
     UPDATE_LABELJSON,
     UPDATE_IMAGEJSON,
-    UPDATE_BIGSHOWJSON
+    UPDATE_BIGSHOWJSON,
+    UPDATE_HOMEJSON
 } from './mutation-types'
 
 export default {
@@ -93,6 +94,11 @@ export default {
     updateBigshowJson({commit},bigshowJson) {
         commit(UPDATE_BIGSHOWJSON,{bigshowJson})
     },
+
+    // 更新homejson
+    updateHomeJson({commit},homeJson) {
+        commit(UPDATE_HOMEJSON,{homeJson})
+    },
 }
 
 

+ 1 - 0
src/renderer/store/mutation-types.js

@@ -14,4 +14,5 @@ export const SECOND_UPDATE_BIGSCREEN = 'second_update_bigscreen' // 间接更新
 export const UPDATE_LABELJSON = 'update_labeljson' // 更新labelJson
 export const UPDATE_IMAGEJSON = 'update_imagejson' // 更新imageJson
 export const UPDATE_BIGSHOWJSON = 'update_bigshowjson' // 更新bigshowJson
+export const UPDATE_HOMEJSON = 'update_homejson' // 更新主页json
 

+ 7 - 1
src/renderer/store/mutations.js

@@ -15,7 +15,8 @@ import {
     SECOND_UPDATE_BIGSCREEN,
     UPDATE_LABELJSON,
     UPDATE_IMAGEJSON,
-    UPDATE_BIGSHOWJSON
+    UPDATE_BIGSHOWJSON,
+    UPDATE_HOMEJSON
 } from './mutation-types'
 
 import storageUtils from "../../utils/storageUtils"
@@ -102,4 +103,9 @@ export default {
     [UPDATE_BIGSHOWJSON](state,{bigshowJson}) {
         state.bigshowJson = bigshowJson
     },
+
+    // 更新homejson
+    [UPDATE_HOMEJSON](state,{homeJson}) {
+        state.homeJson = homeJson
+    },
 }

+ 3 - 0
src/renderer/store/state.js

@@ -35,4 +35,7 @@ export default {
 
   // bigshow的json数据
   bigshowJson:[],
+
+  // 主页json数据
+  homeJson:{}
 }

+ 34 - 101
src/utils/tools.js

@@ -1,107 +1,6 @@
 /*工具函数模块*/
 import axios from 'axios'
 
-// 数组去重
-export function uniq(array){
-    var temp = []; //一个新的临时数组
-    for(var i = 0; i < array.length; i++){
-        if(temp.indexOf(array[i]) == -1){
-            temp.push(array[i]);
-        }
-    }
-    return temp;
-}
-
-// 根据给定的位置给栅格元素进行定位
-export function gridPosition(splitStatus,count) {
-    if(splitStatus === 2){
-        // 四分屏
-        switch (count) {
-            case 1:
-                return '1/1/2/2'
-            case 2:
-                return '1/2/2/3'
-            case 3:
-                return '2/1/3/2'
-            case 4:
-                return '2/2/3/3'
-        }
-    }else if(splitStatus === 3){
-        // 九分屏
-        switch (count) {
-            case 1:
-                return '1/1/2/2'
-            case 2:
-                return '1/2/2/3'
-            case 3:
-                return '1/3/2/4'
-            case 4:
-                return '2/1/3/2'
-            case 5:
-                return '2/2/3/3'
-            case 6:
-                return '2/3/3/4'
-            case 7:
-                return '3/1/4/2'
-            case 8:
-                return '3/2/4/3'
-            case 9:
-                return '3/3/4/4'
-        }
-    }else if(splitStatus === 4){
-        // 十六分屏
-        switch (count) {
-            case 1:
-                return '1/1/2/2'
-            case 2:
-                return '1/2/2/3'
-            case 3:
-                return '1/3/2/4'
-            case 4:
-                return '1/4/2/5'
-            case 5:
-                return '2/1/3/2'
-            case 6:
-                return '2/2/3/3'
-            case 7:
-                return '2/3/3/4'
-            case 8:
-                return '2/4/3/5'
-            case 9:
-                return '3/1/4/2'
-            case 10:
-                return '3/2/4/3'
-            case 11:
-                return '3/3/4/4'
-            case 12:
-                return '3/4/4/5'
-            case 13:
-                return '4/1/5/2'
-            case 14:
-                return '4/2/5/3'
-            case 15:
-                return '4/3/5/4'
-            case 16:
-                return '4/4/5/5'
-        }
-    }
-}
-
-// 时间戳实现节流函数:
-export function throttleFunc(fn, delay) {
-    var previous = 0;
-    // 使用闭包返回一个函数并且用到闭包函数外面的变量previous
-    return function() {
-        var _this = this;
-        var args = arguments;
-        var now = new Date();
-        if(now - previous > delay) {
-            fn.apply(_this, args);
-            previous = now;
-        }
-    }
-}
-
 // 获取绝对位置的横坐标和纵坐标
 export function getElementLeft(element){
     var actualLeft = element.offsetLeft;
@@ -178,4 +77,38 @@ export function elePosition(width,height,count,top,left,splitNum) {
     }
 }
 
+// 获取每个window窗口上需要挂载的元素(接受windowId,返回需要挂载的元素)
+export async function getNeedMoutedEleArr (windowId){
+    const arr = []
+    // 1.大屏
+    const bigScreenJson = await getStaticFile('EnityBigScreen.Data')
+    for (const bigscreen of bigScreenJson){
+        if(bigscreen.WindowID === windowId){
+            arr.push(bigscreen)
+        }
+    }
+    // 2.按钮
+    const buttonJson = await getStaticFile('EnityButton.Data')
+    for (const button of buttonJson){
+        if(button.WindowID === windowId){
+            arr.push(button)
+        }
+    }
+    // 3.label
+    const labelJson = await getStaticFile('EnityLable.Data')
+    for (const label of labelJson){
+        if(label.WindowID === windowId){
+            arr.push(label)
+        }
+    }
+    // 4.image
+    const imageJson = await getStaticFile('EnityImage.Data')
+    for (const image of imageJson){
+        if(image.WindowID === windowId){
+            arr.push(image)
+        }
+    }
+    return arr
+}
+