From 7804a3a4d61ff1d857973e974bbdf78a2e17feab Mon Sep 17 00:00:00 2001
From: shuishen <1109946754@qq.com>
Date: Fri, 17 Dec 2021 15:08:36 +0800
Subject: [PATCH] Merge branch 'master' of http://192.168.0.105:10010/r/school-web
---
src/components/mobilemap/index.vue | 59 +++++++++++++++++++++--------------------------------------
1 files changed, 21 insertions(+), 38 deletions(-)
diff --git a/src/components/mobilemap/index.vue b/src/components/mobilemap/index.vue
index cb27c45..7046ae0 100644
--- a/src/components/mobilemap/index.vue
+++ b/src/components/mobilemap/index.vue
@@ -15,24 +15,19 @@
<mobilePopupOurAfter v-if="mBigPopupAfter"></mobilePopupOurAfter>
<!-- 大弹窗 -->
<mobilePopupOur :style="[bigPopup]" v-if="mBigPopup"></mobilePopupOur>
+ <!-- 测试-跳转位置 -->
+ <mobileGoTo></mobileGoTo>
+ <!-- 实景窗口 -->
+ <mobilePanorama></mobilePanorama>
</div>
</template>
<script>
import { mapGetters } from "vuex";
-import { location } from "../../position/position";
export default {
name: "mobilemapBox",
data() {
return {
DC: "",
- positions: "",
- url: "/img/job/one.jpg",
- srcList: [
- "https://fuss10.elemecdn.com/8/27/f01c15bb73e1ef3793e64e6b7bbccjpeg.jpeg",
- "https://fuss10.elemecdn.com/1/8e/aeffeb4de74e2fde4bd74fc7b4486jpeg.jpeg",
- ],
- popupFlag: false,
- popupWindow: false,
bigPopup: {
width: 0,
height: 0,
@@ -152,22 +147,8 @@
iconUrl: "examples/images/icon/img.png",
name: "影像",
});
- // let nowPosition = "";
- // 地图移动事件
- viewer.on(DC.MouseEventType.MOUSE_MOVE, (e) => {
- if (!that.iconHide) {
- that.$store.commit("MSET_ICONHIDE", true);
- }
- that.$store.dispatch("closeWindowsDom"); //关闭弹窗
- // if (!that.MobileWindowsHide && that.popupsDom) {
- // that.popupsDom.closeOur();
- // that.$store.commit("MSET_MOBILEWINDOWSHIDE", true);
- // }
- // nowPosition = [e.wgs84Position.lng, e.wgs84Position.lat];
- // console.log(nowPosition);
- });
- // // eslint-disable-next-line camelcase
+ // eslint-disable-next-line camelcase
// const baselayer_shaded = DC.ImageryLayerFactory.createArcGisImageryLayer({
// url: "http://services.arcgisonline.com/arcgis/rest/services/World_Shaded_Relief/MapServer",
// });
@@ -193,6 +174,20 @@
// iconUrl: "examples/images/icon/ter.png",
// name: "地形",
// });
+
+ // 地图移动事件
+ viewer.on(DC.MouseEventType.MOUSE_MOVE, (e) => {
+ if (!that.iconHide) {
+ that.$store.commit("MSET_ICONHIDE", true);
+ }
+ that.$store.dispatch("closeMobileWindowsDom"); //关闭弹窗
+ // if (!that.MobileWindowsHide && that.popupsDom) {
+ // that.popupsDom.closeOur();
+ // that.$store.commit("MSET_MOBILEWINDOWSHIDE", true);
+ // }
+ // nowPosition = [e.wgs84Position.lng, e.wgs84Position.lat];
+ // console.log(nowPosition);
+ });
const layer = new DC.TilesetLayer("layer");
viewer.addLayer(layer);
@@ -226,7 +221,7 @@
viewer.scene.globe.depthTestAgainstTerrain = false;
// console.log(document.getElementById("mobile-map_content_content"));
- // console.log(e.position);
+ console.log(e);
// 定制化窗体
that.openPopupS(e.position, [e.wgs84Position.lng, e.wgs84Position.lat]);
@@ -256,21 +251,9 @@
position,
lntLat,
query: { ...(query || {}), position, lntLat },
+ useJWD: true, //仅使用经纬度
};
that.$store.dispatch("setMobileWindows", d);
- },
- getLocation() {
- // let _that = this;
- // let geolocation = location.initMap("map-container"); //定位
- // AMap.event.addListener(geolocation, "complete", (result) => {
- // console.log(result);
- // // console.log("hhha");
- // // _that.lat = result.position.lat;
- // // _that.lng = result.position.lng;
- // // _that.province = result.addressComponent.province;
- // // _that.city = result.addressComponent.city;
- // // _that.district = result.addressComponent.district;
- // });
},
},
};
--
Gitblit v1.9.3