liuyg
2021-12-16 997262e44f7f9e8d0cde869cfd026ef8c0850efd
src/components/mobilePopupOurOnce/index.vue
@@ -31,6 +31,14 @@
export default {
  props: ["onceData"],
  name: "mobilePopupOurOnce",
  created() {
    this.DC = global.DC;
  },
  data() {
    return {
      DC: "",
    };
  },
  computed: {
    ...mapGetters(["mviewer"]),
    seebut() {
@@ -46,17 +54,26 @@
  },
  methods: {
    openOnce(val) {
      console.log(val, this.onceData.name);
      // 定位
      // this.mviewer.zoomToPosition(
      //     new DC.Position(
      //       e.wgs84Position.lng,
      //       e.wgs84Position.lat - 0.016,
      //       1530,
      //       0,
      //       -45
      //     )
      //   );
      let that = this;
      console.log(val, this.onceData);
      if (val == "定位") {
        this.$store.commit("MSET_BIGPOPUP", false);
        setTimeout(() => {
          // that.$refs.mobilemapBoxFrom.openPopupS(
          //   this.onceData.Cartesian3,
          //   this.onceData.position
          // );
          that.$parent.$parent.$parent.$parent.openPopupS(
            this.onceData.Cartesian3,
            this.onceData.position
          );
          // console.log(that.$refs.mobilemapBoxFrom);
          // 定位 打开弹窗
          // this.mviewer.zoomToPosition(
          //   new that.DC.Position(p[0], p[1] - 0.016, 1530, 0, -45)
          // );
        }, 500);
      }
    },
  },
};