maxiaoxiao 7 months ago
parent
commit
a185fb0953

+ 1 - 1
src/components/echartsTemplate/pie.vue

@@ -256,7 +256,7 @@ export default {
       } else {
         option.title.show = false;
       }
-      console.log(cartData.title, "cartData.tltle");
+      // console.log(cartData.title, "cartData.tltle");
 
       if (cartData.title) {
         option.title.show = true;

+ 13 - 12
src/views/LandConsolidation/components/contrast.vue

@@ -110,8 +110,8 @@ export default {
         store.setJlServer("zz", res.data);
       }
 
-      this.dbdata.zzq_server = store.state.jlserver.zz.zzq_server;
-      this.dbdata.zzh_server = store.state.jlserver.zz.zzh_server;
+      this.dbdata.zzq = store.state.jlserver.zz.zzq_server;
+      this.dbdata.zzh = store.state.jlserver.zz.zzh_server;
     },
     checkedChange(value) {
       console.log(value);
@@ -143,13 +143,12 @@ export default {
         //   useRoller(true, "lrRoller", "leftRoller", "", false);
         //   setImageryRoller(layer);
         // });
-        // this.nolayer = this.layersData[1].year;
         store.setaddNode([
-          { id: "ttzz", url: this.dbdata.zzq_server, label: "土地整治对比" },
+          { id: "ttzz", url: this.dbdata.zzq, label: "土地整治对比" },
         ]);
-        this.setImager({ url: this.dbdata.zzq_server, year: "qian" }, true);
+        this.setImager({ url: this.dbdata.zzq, year: "qian", top: true }, true);
         this.setImager(
-          { url: this.dbdata.zzh_server, year: "hou" },
+          { url: this.dbdata.zzh, year: "hou", top: true },
           true,
           (layer) => {
             useRoller(true, "lrRoller", "leftRoller", "", false);
@@ -168,14 +167,15 @@ export default {
         this.$refs.aside.clickHandler();
       } else {
         this.$refs.aside.clearTimer();
-        // this.nolayer = this.layersData[0].year;
-        // this.layersData.forEach((img) => {
-        //   this.setImager(img, false);
-        // });
       }
       if (this.active == 1 || this.active == -1) {
         this.nolayer = this.layersData[0].year;
         this.setImager(this.layersData[0], true);
+        this.setImager({ year: "qian" }, false);
+        this.setImager({ year: "hou" }, false);
+        // this.layersData.forEach((img) => {
+        //   this.setImager(img, false);
+        // });
       }
     },
     async Getlayers() {
@@ -192,7 +192,7 @@ export default {
       }
     },
     setImager(obj, isshow = true, fun) {
-      console.log(obj, obj.year, isshow, this.imagelayers[obj.year], "---");
+      console.log(obj.year, isshow, this.imagelayers[obj.year], "---");
 
       if (this.imagelayers[obj.year]) this.imagelayers[obj.year].show = isshow;
       else if (isshow)
@@ -202,6 +202,7 @@ export default {
             name: obj.year,
           })
         );
+      if (obj.top) viewer.imageryLayers.raiseToTop(this.imagelayers[obj.year]);
       fun && fun(this.imagelayers[obj.year]);
       // viewer.flyTo(this.imagelayers[obj.year]);
     },
@@ -247,7 +248,7 @@ export default {
   },
   watch: {
     nolayer(newVal, oldVal) {
-      console.log(newVal, oldVal, "---nolayer");
+      console.log(newVal, "---nolayer", oldVal, "---nolayer");
       if (oldVal) this.setImager({ year: oldVal }, false);
     },
   },

+ 1 - 1
src/views/LandConsolidation/components/sdgk.vue

@@ -248,7 +248,7 @@ export default {
       if (!isshow) type && this.flyTo(type == "sd" ? 0 : 1);
       else removeGeoJSON("zlhig");
       Object.keys(geoSources).forEach((name) => {
-        console.log(name, geoSources[name]);
+        // console.log(name, geoSources[name]);
         geoSources[name].show = isshow;
       });
     },

+ 0 - 1
src/views/LandConsolidation/index.vue

@@ -203,7 +203,6 @@ export default {
         jscType: "qytuzz_sdzl_sdmb_ssfa",
         id: this.xzqh,
       });
-      console.log(res.data);
       this.filelist = res.data.zzwafile.split(",");
     },
     handleClick() {},