From c333c671ef1541171c96d11b0266fdc0237665c8 Mon Sep 17 00:00:00 2001
From: liuyg <376836862@qq.com>
Date: Thu, 23 Dec 2021 14:00:41 +0800
Subject: [PATCH] +街道位置
---
src/components/mobileCortrolButtom/index.vue | 9 +++++----
src/store/getters.js | 3 ++-
src/components/mobileGoTo/index.vue | 5 +++++
3 files changed, 12 insertions(+), 5 deletions(-)
diff --git a/src/components/mobileCortrolButtom/index.vue b/src/components/mobileCortrolButtom/index.vue
index 251dacc..f325322 100644
--- a/src/components/mobileCortrolButtom/index.vue
+++ b/src/components/mobileCortrolButtom/index.vue
@@ -69,14 +69,15 @@
},
handleCommand(command) {
let that = this;
+ let position = [+command.lnt + 0.01197, +command.lat - 0.0021];
console.log(command, "定位");
// 定位
- this.$store.commit("MSETCC_SETCC", {
- lntLat: [command.lnt, command.lat],
- });
+ // this.$store.commit("MSETCC_SETCC", {
+ // lntLat: position,
+ // });
this.$store.dispatch("mapFlyTo", {
//飞入
- lntLat: [command.lnt, command.lat, 500],
+ lntLat: [...position, 500],
heading: 0,
pitch: -45,
roll: 0,
diff --git a/src/components/mobileGoTo/index.vue b/src/components/mobileGoTo/index.vue
index 5da6cba..9122866 100644
--- a/src/components/mobileGoTo/index.vue
+++ b/src/components/mobileGoTo/index.vue
@@ -17,6 +17,7 @@
"mviewer",
"query",
"MobileWindowChangeData",
+ "ccDataState",
]),
},
data() {
@@ -31,6 +32,10 @@
this.lnt = this.query.lntLat[0];
this.lat = this.query.lntLat[1];
},
+ ccDataState() {
+ this.lnt = this.query.lntLat[0];
+ this.lat = this.query.lntLat[1];
+ },
},
methods: {
submitForm() {
diff --git a/src/store/getters.js b/src/store/getters.js
index 932cd75..00099e1 100644
--- a/src/store/getters.js
+++ b/src/store/getters.js
@@ -10,7 +10,8 @@
MobileWindowChangeData: state => state.mobile.MobileWindowChangeData,//随地图移动窗口
popupsDom: state => state.mobile.popupsDom,
query: state => state.mobile.query,
- openmobileGoTo: state => state.mobile.openmobileGoTo,
+ openmobileGoTo: state => state.mobile.openmobileGoTo,//测试
+ ccDataState: state => state.mobile.ccDataState,//测试
openmobilePanorama: state => state.mobile.openmobilePanorama,
MobileWindowsHideFixed: state => state.mobile.MobileWindowsHideFixed,//固定窗口
MobileWindowChangeDataFixed: state => state.mobile.MobileWindowChangeDataFixed,//固定窗口
--
Gitblit v1.9.3