北京经济技术开发区经开区虚拟城市项目-【前端】--政府服务中心-1号屏Web
Surpriseplus
2023-10-07 a77448eb072f10dd3827694140f87c3069b1dba4
src/components/index.vue
@@ -1,7 +1,11 @@
<template>
  <div class="mapViewer">
    <leftpanel ref="Left" v-show="false" />
    <leftpanel
      ref="Left"
      v-show="false"
    />
    <bottommenu />
    <left-menu v-if="queryShow"></left-menu>
    <viewer class="mapViewer" />
  </div>
</template>
@@ -10,13 +14,15 @@
import viewer from "@/components/map/viewer";
import leftpanel from "@/components/left/index";
import bottommenu from "@/components/menu/bottom-menu";
import leftMenu from "@/components/menu/leftMenu.vue";
import vueEvents from '@/utils/vueEvent.js'
export default {
  name: "index",
  components: {
    viewer,
    leftpanel,
    bottommenu,
    leftMenu
  },
  data() {
    return {
@@ -25,6 +31,7 @@
      offset: "0%",
      tooltipInfo: "请稍后。。。",
      tooltipShow: false,
      queryShow: false,
    };
  },
  mounted() {
@@ -32,9 +39,18 @@
    this.scale = (100 / size).toFixed(2);
    this.offset = "-" + ((size - 100) / 2).toFixed(2) + "%";
    this.size = size + "%";
    // this.queryShow = rpc.isShow;
    vueEvents.$on('queryLayer', (res) => {
      this.queryShow = res
    })
  },
  watch: {},
  methods: {
    queryShow(res) {
      this.queryShow = res;
    }
  },
  watch: {
  },
  methods: {
    detectZoom() {
      var ratio = 0,