shuishen
2021-12-17 b5f8881176bcb44928758e25d7d7a6fc140840c5
src/components/orgNavBar/index.vue
@@ -37,6 +37,9 @@
<script>
import { mapGetters } from 'vuex'
var $ = window.$
export default {
    name: 'OrgNavBar',
    data () {
@@ -64,7 +67,13 @@
            // 点信息
            'pointPosition',
            // 点名称
            'stateName'
            'stateName',
            // 地址
            'siteName',
            // 介绍
            'introduceText',
            // 全景地址
            'panoramaUrl'
        ])
    },
    methods: {
@@ -118,14 +127,15 @@
            this.$parent.closeModel()
        },
        mapPopup (item) {
            this.$store.commit('CLEAR_ALL', null)
            this.$store.commit('SET_POPUPBGURL', item.bgImg)
            this.$store.commit('SET_POPUPQRURL', item.QRImg)
            this.$store.commit('SET_POINTPOSITION', [item.longitude, item.latitude, item.alt, item.heading, item.pitch, item.roll])
            this.$store.commit('SET_POINTPOSITION', [Number(item.longitude), Number(item.latitude), Number(item.alt), Number(item.heading), Number(item.pitch), Number(item.roll)])
            this.$store.commit('SET_STATENAME', item.navTitle)
            console.log(this.popupBgUrl)
            var that = this
            // item.alt, item.heading, item.pitch, item.roll
            this.viewer.zoomToPosition(
                new this.DC.Position(item.longitude, item.latitude, item.alt, item.heading, item.pitch, item.roll),
                function () {
@@ -135,16 +145,16 @@
        },
        newPopup (item) {
            const position = this.DC.Transform.transformWGS84ToCartesian(new this.DC.Position(item.longitude, item.latitude, item.alt, item.heading, item.pitch, item.roll))
            // eslint-disable-next-line new-cap
            var popup = new this.DC.divForms(this.viewer, {
                domId: 'div1',
                title: item.navTitle,
                className: 'divForms-dom',
                content: document.getElementById('mapChildContent'),
            // eslint-disable-next-line no-unused-vars
            var popup = new this.DC.DivForms(this.viewer, {
                domId: 'divFormsDomBox',
                position: [
                    position
                ]
            })
            this.$store.commit('SET_PANORAMAPOPUP', false)
            this.$store.commit('SET_DETAILSPOPUP', true)
        }
    }
}