shuishen
2021-12-21 0b9095227438cb35f5a8759aee8f3b32a732151c
src/components/arcNavBar/index.vue
@@ -6,7 +6,7 @@
                 @mousedown="move"
                 :class="{'move': moveFlag}">
                <div class="title">
                    <img class="icon"
                    <img class="icon deblurring"
                         src="/img/icon/xyjz.png"
                         alt="">
                    <span>
@@ -46,8 +46,6 @@
<script>
import { mapGetters } from 'vuex'
import { getList, getChildNavList, getChildNavDetail } from '@/api/pc/public/arc'
var $ = window.$
export default {
    name: 'ArcNavBar',
@@ -163,7 +161,7 @@
            getChildNavList({ campus: campus, type: this.arcCode }).then(res => {
                res.data.data.forEach(item => {
                    this.itemNavList.push({
                        navTitle: item.mechanismName,
                        navTitle: item.mechanismname,
                        icon: '/img/navicon/tag.png',
                        id: item.id
                    })
@@ -175,27 +173,36 @@
                var result = res.data.data[0].list
                this.$store.commit('CLEAR_ALL', null)
                this.$store.commit('SET_POPUPBGURL', result.tpUrl)
                this.$store.commit('SET_POPUPQRURL', result.codeUrl)
                var imgArr = result.tpurl.split(',')
                var tabOne = res.data.data[0].jx.split(',')
                this.$store.commit('SET_POPUPBGURL', imgArr[0])
                this.$store.commit('SET_POPUPQRURL', result.codeurl)
                this.$store.commit('SET_POINTPOSITION', [Number(result.jd), Number(result.wd), Number(result.gd), Number(result.heading), Number(result.pitch), Number(result.roll)])
                this.$store.commit('SET_STATENAME', result.mechanismName)
                this.$store.commit('SET_STATENAME', result.mechanismname)
                this.$store.commit('SET_SITENAME', result.address)
                this.$store.commit('SET_TELEPHONE', result.telephone)
                this.$store.commit('SET_INTRODUCETEXT', result.introduce)
                this.$store.commit('SET_PANORAMAURL', result.panoramaurl)
                this.$store.commit('SET_POPUPIMGATLAS', imgArr)
                if (res.data.data[0].jx != '') {
                    this.$store.commit('SET_TEACHLIST', tabOne)
                } else {
                    this.$store.commit('SET_TEACHLIST', [])
                }
                this.$store.commit('SET_LIVELIST', [])
                var that = this
                // item.alt, item.heading, item.pitch, item.roll
                this.viewer.zoomToPosition(
                    new this.DC.Position(result.jd, result.wd, result.gd, result.heading, result.pitch, result.roll),
                this.newPopup(result)
                this.viewer.flyToPosition(
                    new this.DC.Position(Number(result.jd), Number(result.wd), 3000, Number(result.heading), Number(result.pitch), Number(result.roll)),
                    function () {
                        that.newPopup(result)
                    }
                    },
                    3
                )
                // res.data.data[0].jx
            })
        },
        newPopup (item) {
            const position = this.DC.Transform.transformWGS84ToCartesian(new this.DC.Position(item.jd, item.wd, item.gd, item.heading, item.pitch, item.roll))
            const position = this.DC.Transform.transformWGS84ToCartesian(new this.DC.Position(Number(item.jd), Number(item.wd), Number(item.gd), Number(item.heading), Number(item.pitch), Number(item.roll)))
            // eslint-disable-next-line no-unused-vars
            var popup = new this.DC.DivForms(this.viewer, {
                domId: 'divFormsDomBox',
@@ -219,7 +226,7 @@
    border-radius: 8px;
    top: 24%;
    left: 20%;
    background-color: #fff;
    background-color: transparent;
    z-index: 999;
    font-size: 14px;
    .container {
@@ -229,12 +236,23 @@
            width: 100%;
            height: 36px;
            line-height: 36px;
            background-color: #020c17;
            background: rgba(0, 131, 176, 0.9); /* fallback for old browsers */
            background: -webkit-linear-gradient(
                to left,
                rgba(0, 180, 219, 0.9),
                rgba(0, 131, 176, 0.9)
            ); /* Chrome 10-25, Safari 5.1-6 */
            background: linear-gradient(
                to left,
                rgba(0, 180, 219, 0.9),
                rgba(0, 131, 176, 0.9)
            ); /* W3C, IE 10+/ Edge, Firefox 16+, Chrome 26+, Opera 12+, Safari 7+ */
            .title {
                padding-left: 10px;
                img {
                    width: 18px;
                    height: 18px;
                    width: 20px;
                    height: 20px;
                    vertical-align: middle;
                }
                span {
@@ -265,8 +283,19 @@
            margin-top: 0px;
            text-align: center;
            overflow-y: auto;
            background: url(/img/bg/nav-bg.jpeg) no-repeat;
            background-size: 100% 100%;
            background: rgba(0, 131, 176, 0.9); /* fallback for old browsers */
            background: -webkit-linear-gradient(
                to left,
                rgba(0, 180, 219, 0.9),
                rgba(0, 131, 176, 0.9)
            ); /* Chrome 10-25, Safari 5.1-6 */
            background: linear-gradient(
                to left,
                rgba(0, 180, 219, 0.9),
                rgba(0, 131, 176, 0.9)
            ); /* W3C, IE 10+/ Edge, Firefox 16+, Chrome 26+, Opera 12+, Safari 7+ */
            border-radius: 0 0 8px 8px;
            .tab {
                height: 42px;
                border-bottom: 1px solid #ccc;