智慧农业大数据平台
guoshilong
2022-09-27 b2e3aa019e2705d8aa13ba863155b42513f84c12
src/components/remote/index.vue
@@ -142,6 +142,11 @@
    },
    created () {
        this.farmSelectList=viewdata
        this.currentTitle= viewdata.selectItem.name
        this.timeLineList= viewdata[0].childItem
        this.currentObj= viewdata[0].selectItem
        this.currentInd = viewdata[0].selectItem.index
        // this.leftRollerLayers = [
        //         {
        //     title: '2022年6月影像',
@@ -308,11 +313,10 @@
                    maximumLevel: 18
                })
            )
            viewdata.forEach(item => {
                global.viewer.imageryLayers.addImageryProvider(
                    new global.DC.Namespace.Cesium.UrlTemplateImageryProvider({
                        url: item.childItem[0].url,
                        url: item.selectItem.url,
                        maximumLevel: 18
                    })
                )
@@ -395,8 +399,18 @@
        // 遥感监测多时相基地下拉事件
        selectItem (item, index) {
            this.timeLineList = item.childItem
            this.currentObj = this.timeLineList[0]
            this.currentInd = 0
            if(this.timeLineList.some(e=>{return e.type == "0"})){
                for(var i = 0; i<this.timeLineList.length;i++){
                    if(this.timeLineList[i].type == "0"){
                        this.currentObj = this.timeLineList[i]
                        this.currentInd = i
                        break
                    }
                }
            }else{
                this.currentObj = this.timeLineList[0]
                this.currentInd = 0
            }
            this.goToDcBylatlon(item.latitude, item.longitude)
        },
        // 遥感监测卷帘左基地下拉事件