瀏覽代碼

点击逻辑修改

zpf 1 年之前
父節點
當前提交
94db9f86bc
共有 1 個文件被更改,包括 3 次插入5 次删除
  1. 3 5
      src/views/viewer.vue

+ 3 - 5
src/views/viewer.vue

@@ -126,7 +126,6 @@ export default {
             this.flag = !this.flag;
         },
         setDatas() {
-            console.log(111);
 
             // 耕地保护
             this.$refs.gdbh_ref.init_zbph(this.params);
@@ -228,16 +227,15 @@ export default {
                 let height = cartographic.height;
                 let heading = viewer.scene.camera.heading;
                 let pitch = viewer.scene.camera.pitch;
-                // that.addSceneFun()
 
                 if (!position) {
                     position = Cesium.Cartesian3.fromDegrees(0, 0, 0);
                     return;
                 }
-                if (store.state.xzqh_flag) {
+
+                if (store.state.viewer_flag) {
                     if (Cesium.defined(pickObj)) {
-                        console.log(store.state.xzqh_flag, "store.state.xzqh_flag");
-                        if (pickObj.primitive instanceof Cesium.Primitive && store.state.xzqh_flag == true) {//点击primitive
+                        if (pickObj.primitive instanceof Cesium.Primitive) {//点击primitive
                             //primitive相关操作
 
                             let obj = JSON.parse(pickObj.id);