From bf58722dfd03ea1513f3acc7331d4d4403fca76e Mon Sep 17 00:00:00 2001
From: shuishen <1109946754@qq.com>
Date: Fri, 18 Mar 2022 11:48:37 +0800
Subject: [PATCH] Merge branch 'master' of http://192.168.0.105:10010/r/school-web
---
src/components/mobileCortrolButtom/index.vue | 85 +++++++++++++++++++++++++++++++++++-------
1 files changed, 71 insertions(+), 14 deletions(-)
diff --git a/src/components/mobileCortrolButtom/index.vue b/src/components/mobileCortrolButtom/index.vue
index 5381441..d3bf472 100644
--- a/src/components/mobileCortrolButtom/index.vue
+++ b/src/components/mobileCortrolButtom/index.vue
@@ -22,8 +22,14 @@
</div>
<!-- <div class="m-l-inbut" @click="openActivity">
<i class="el-icon-s-opportunity"></i>
- </div> -->
- <!-- <div class="m-l-inbut" @click="goOn"><i class="el-icon-location"></i></div> -->
+ </div>-->
+ <div class="m-l-inbut" @click="zoomIns">
+ <i class="el-icon-refresh"></i>
+ </div>
+ <div class="m-l-inbut" @click="goOns"><i class="el-icon-location"></i></div>
+ <div class="m-l-inbut" @click="openOurSee">
+ <i class="el-icon-map-location"></i>
+ </div>
</div>
</template>
@@ -36,7 +42,6 @@
name: "mobileCortrolButtom",
data() {
return {
- DC: "",
tabTable: [],
ccData: [
{
@@ -59,16 +64,68 @@
};
},
computed: {
- ...mapGetters(["mviewer", "openmobileGoTo", "dimensionData"]),
+ ...mapGetters([
+ "openmobileGoTo",
+ "dimensionData",
+ // "startPointFn",
+ "dimension",
+ ]),
},
created() {
- this.DC = global.DC;
// this.getStreet();
},
mounted() {},
methods: {
+ openOurSee() {
+ this.$store.commit(
+ "MSET_OPENMOBILEPANORAMA",
+ "http://vr.jxpskj.com/lxxqw/"
+ );
+ },
+ goOns() {
+ let that = this;
+ this.$store.commit("GET_NOWPOSITION", (res) => {
+ that.$store.dispatch("pcMoveView", {
+ jd: res[0],
+ wd: res[1],
+ viewer: global.viewer,
+ });
+
+ let data = [
+ {
+ name: "我的位置",
+ jd: res[0],
+ wd: res[1],
+ },
+ ];
+ that.$store.dispatch("addLabelLayerIconMobelUse", {
+ list: data,
+ clear: true,
+ mviewer: global.viewer,
+ });
+ });
+ },
+ zoomIns(val) {
+ // this.$store.dispatch("mapFlyTo", {
+ // //飞入
+ // lntLat: [115.87988885, 28.72502592, 2100],
+ // // lntLat: [115.87186406, 28.74449337, 1200],
+ // // lntLat: [121.50492752204283, 31.21567802276832, 2530],
+ // heading: 0,
+ // pitch: -45,
+ // roll: 0,
+ // noOpen: true,
+ // });
+ // if (val) {
+ // if (this.dimension != val) {
+ // this.$store.dispatch("MSET_DIMENSIONS", val);
+ // }
+ // return;
+ // }
+ window.startPointFn();
+ },
openActivity() {
- let d = {
+ const d = {
main: [
{
name: "活动",
@@ -83,12 +140,11 @@
// this.$store.commit("set_showActivity", true);
},
mubiao() {
- let that = this;
- //测试fllyTo
+ // 测试fllyTo
},
handleCommand(command) {
- let that = this;
- let position = [+command.lnt + 0.00027, +command.lat + 0.00048, 450];
+ const that = this;
+ const position = [+command.lnt + 0.00027, +command.lat + 0.00048, 450];
console.log(command, "定位");
// 定位
// this.$store.commit("MSETCC_SETCC", {
@@ -102,9 +158,10 @@
// roll: 0,
// noOpen: true,
// });
- that.mviewer.camera.setView({
+ global.viewer.camera.setView({
// Cesium的坐标是以地心为原点,一向指向南美洲,一向指向亚洲,一向指向北极州
// fromDegrees()方法,将经纬度和高程转换为世界坐标
+ // eslint-disable-next-line new-cap
destination: new global.DC.Namespace.Cesium.Cartesian3.fromDegrees(
// 114.0351,
// 27.6314,
@@ -130,7 +187,7 @@
this.$store.commit("MSET_BIGPOPUPAFTER", true);
},
goOn() {
- let that = this;
+ const that = this;
this.$store.commit("MSET_OPENMOBILEGOTO", !that.openmobileGoTo);
// console.log(returnCitySN["cip"]);
// let data = {
@@ -144,9 +201,9 @@
// });
},
getStreet() {
- let that = this;
+ const that = this;
getListarc().then((res) => {
- let title = [];
+ const title = [];
const data = res.data.data;
for (let k = 0; k < data.length; k++) {
title.push({
--
Gitblit v1.9.3