From 0fa88f9c2e3c8ce335e7cd6dfc6c8e5641950735 Mon Sep 17 00:00:00 2001
From: liuyg <376836862@qq.com>
Date: Wed, 09 Feb 2022 15:53:24 +0800
Subject: [PATCH] +弹窗图片可点击,列表展示文字区域点击是定位,图片可点击,+活动打开后隐藏右侧控制栏,+操作方式更改
---
src/components/orgNavBar/index.vue | 63 ++++++++++++++++++-------------
1 files changed, 37 insertions(+), 26 deletions(-)
diff --git a/src/components/orgNavBar/index.vue b/src/components/orgNavBar/index.vue
index d8f67e1..9a4405c 100644
--- a/src/components/orgNavBar/index.vue
+++ b/src/components/orgNavBar/index.vue
@@ -10,7 +10,7 @@
src="/img/icon/jg.png"
alt="">
<span>
- {{title}}
+ {{orgNavBarTitle}}
</span>
</div>
<img class="close"
@@ -20,7 +20,7 @@
</div>
<div class="content">
<ul>
- <li v-for="(item, index) in navList"
+ <li v-for="(item, index) in orgNavBarList"
:key="index"
@click="mapPopup(item)">
<img :src="item.icon"
@@ -46,14 +46,6 @@
DC: null
}
},
- props: {
- navList: {
- type: Array
- },
- title: {
- type: String
- }
- },
created () {
this.DC = global.DC
},
@@ -71,7 +63,9 @@
// 介绍
'introduceText',
// 全景地址
- 'panoramaUrl'
+ 'panoramaUrl',
+ 'orgNavBarList',
+ 'orgNavBarTitle'
])
},
methods: {
@@ -121,9 +115,7 @@
document.onmouseup = null
}
},
- closeModel () {
- this.$parent.closeModel()
- },
+
mapPopup (item) {
this.$store.commit('CLEAR_ALL', null)
@@ -137,17 +129,21 @@
this.$store.commit('SET_TELEPHONE', item.telephone)
this.$store.commit('SET_INTRODUCETEXT', item.introduce)
this.$store.commit('SET_POPUPIMGATLAS', imgArr)
+ if (item.videourl && item.videourl != '') {
+ this.$store.commit('SET_MONITORURL', item.videourl)
+ }
this.newPopup(item)
this.viewer.flyToPosition(
- new this.DC.Position(Number(item.longitude), Number(item.latitude), 3000, Number(item.heading), Number(item.pitch), Number(item.roll)),
+ new this.DC.Position(Number(item.longitude), Number(item.latitude), 300, Number(item.heading), Number(item.pitch), Number(item.roll)),
function () {
},
3
)
},
+
newPopup (item) {
- const position = this.DC.Transform.transformWGS84ToCartesian(new this.DC.Position(Number(item.longitude), Number(item.latitude), Number(item.alt), Number(item.heading), Number(item.pitch), Number(item.roll)))
+ const position = this.DC.Transform.transformWGS84ToCartesian(new this.DC.Position(Number(item.longitude), Number(item.latitude), Number(item.alt)))
// eslint-disable-next-line no-unused-vars
var popup = new this.DC.DivForms(this.viewer, {
domId: 'divFormsDomBox',
@@ -157,7 +153,22 @@
})
this.$store.commit('SET_PANORAMAPOPUP', false)
+ this.$store.commit('SET_MONITORPOPUP', false)
this.$store.commit('SET_DETAILSPOPUP', true)
+ },
+
+ closeModel () {
+ var path = this.$route.path
+ if (path.indexOf('/orgnav') != -1) {
+ this.$store.dispatch('delVisitedViews', this.$route)
+ this.$router.push('/pcLayout/default')
+ }
+
+ this.$store.commit('SET_ORGNAVBARTITLE', '')
+
+ this.$store.commit('SET_ORGNAVBARFLAG', false)
+
+ this.$store.commit('SET_ORGNAVBARLIST', [])
}
}
}
@@ -182,16 +193,16 @@
width: 100%;
height: 36px;
line-height: 36px;
- background: rgba(0, 131, 176, 0.9); /* fallback for old browsers */
+ background: rgba(0, 131, 176, 0.7); /* fallback for old browsers */
background: -webkit-linear-gradient(
to left,
- rgba(0, 180, 219, 0.9),
- rgba(0, 131, 176, 0.9)
+ rgba(0, 180, 219, 0.7),
+ rgba(0, 131, 176, 0.7)
); /* Chrome 10-25, Safari 5.1-6 */
background: linear-gradient(
to left,
- rgba(0, 180, 219, 0.9),
- rgba(0, 131, 176, 0.9)
+ rgba(0, 180, 219, 0.7),
+ rgba(0, 131, 176, 0.7)
); /* W3C, IE 10+/ Edge, Firefox 16+, Chrome 26+, Opera 12+, Safari 7+ */
.title {
@@ -235,16 +246,16 @@
margin-top: 0px;
text-align: center;
overflow-y: auto;
- background: rgba(0, 131, 176, 0.9); /* fallback for old browsers */
+ background: rgba(0, 131, 176, 0.7); /* fallback for old browsers */
background: -webkit-linear-gradient(
to left,
- rgba(0, 180, 219, 0.9),
- rgba(0, 131, 176, 0.9)
+ rgba(0, 180, 219, 0.7),
+ rgba(0, 131, 176, 0.7)
); /* Chrome 10-25, Safari 5.1-6 */
background: linear-gradient(
to left,
- rgba(0, 180, 219, 0.9),
- rgba(0, 131, 176, 0.9)
+ rgba(0, 180, 219, 0.7),
+ rgba(0, 131, 176, 0.7)
); /* W3C, IE 10+/ Edge, Firefox 16+, Chrome 26+, Opera 12+, Safari 7+ */
border-radius: 0 0 8px 8px;
--
Gitblit v1.9.3