rui.jiang 14 시간 전
부모
커밋
918904f20e
4개의 변경된 파일42개의 추가작업 그리고 42개의 파일을 삭제
  1. 3 4
      .env.demo
  2. 1 1
      .env.hd
  3. 37 37
      src/components/map/index.vue
  4. 1 0
      vue.config.js

+ 3 - 4
.env.demo

@@ -29,9 +29,8 @@ VUE_APP_TITLE='机组功率曲线异常检测数据分析系统'
 
 #内网
 VUE_APP_UPLOAD="http://192.168.50.235/energy-manage-service/api/check/upload"
-VUE_APP_MAPVIEW=/tiles/{z}/{x}/{y}.png
-VUE_APP_MAP=http://192.168.50.235:8998
-# VUE_APP_MAPVIEW=http://192.168.50.235/tiles/{z}/{x}/{y}.png
+VUE_APP_MAP="http://192.168.50.235:8998"
+VUE_APP_MAPVIEW="http://192.168.50.235/tiles/{z}/{x}/{y}.png"
 VUE_APP_APIPROXY='http://192.168.50.235:16600'
 VUE_APP_WZLAPIPROXY='http://192.168.50.235:8998/transDataWeb'
 VUE_APP_ETLAPIPROXY='http://192.168.50.235:8998/transDataWeb'
@@ -39,4 +38,4 @@ VUE_APP_AnalysisMultiAPIPROXY='http://192.168.50.235:8998/AnalysisMulti'
 # #自定义算法文佳 目前无法使用,可能是服务未启动
 VUE_APP_sAlgorithmAPIPROXY='http://192.168.50.235:8998/sAlgorithm'
 VUE_APP_databaseApiAPIPROXY='http://192.168.50.234:3002'
-VUE_APP_downLoadChartAPIPROXY='http://192.168.50.235:8999/downLoadChart'
+VUE_APP_downLoadChartAPIPROXY='http://192.168.50.235:8998/downLoadChart'

+ 1 - 1
.env.hd

@@ -32,4 +32,4 @@ VUE_APP_downLoadChartAPIPROXY='http://106.120.102.238:58880'
 # #暂时不知健康评估内网dev 环境地址
 # VUE_APP_AnalysisMultiAPIPROXY='http://192.168.50.235:8998/AnalysisMulti'
 # #暂时不知下载报告内网dev 环境地址
-# VUE_APP_downLoadChartAPIPROXY=''
+# VUE_APP_downLoadChartAPIPROXY='http://192.168.50.235:8998/downLoadChart'

+ 37 - 37
src/components/map/index.vue

@@ -270,45 +270,45 @@ export default {
     });
 
     // -------------【添加山西省真实边界线】------------- 定位全国的时候注释这个代码
-    if (this.$route.path === "/home/cockpitManage") {
-      // 通过导入的 JSON 文件加载边界数据(GeoJSON 格式),并解析成矢量要素
-      const shanxiSource = new Vector({
-        features: new GeoJSON().readFeatures(shanxiBoundary, {
-          featureProjection: "EPSG:4326",
-        }),
-      });
-      // 创建矢量图层,仅显示边界线(填充颜色设为透明)
-      const shanxiLayer = new VectorLayer({
-        source: shanxiSource,
-        style: new Style({
-          stroke: new Stroke({
-            color: "rgba(59, 130, 246, 0.5)",
-            width: 3,
-          }),
-          fill: new Fill({
-            color: "rgba(59, 130, 246, 0.05)", // 透明填充
-          }),
-        }),
-      });
-      this.map.addLayer(shanxiLayer);
+    // if (this.$route.path === "/home/cockpitManage") {
+    //   // 通过导入的 JSON 文件加载边界数据(GeoJSON 格式),并解析成矢量要素
+    //   const shanxiSource = new Vector({
+    //     features: new GeoJSON().readFeatures(shanxiBoundary, {
+    //       featureProjection: "EPSG:4326",
+    //     }),
+    //   });
+    //   // 创建矢量图层,仅显示边界线(填充颜色设为透明)
+    //   const shanxiLayer = new VectorLayer({
+    //     source: shanxiSource,
+    //     style: new Style({
+    //       stroke: new Stroke({
+    //         color: "rgba(59, 130, 246, 0.5)",
+    //         width: 3,
+    //       }),
+    //       fill: new Fill({
+    //         color: "rgba(59, 130, 246, 0.05)", // 透明填充
+    //       }),
+    //     }),
+    //   });
+    //   this.map.addLayer(shanxiLayer);
 
-      const markerLayer = this.map
-        .getLayers()
-        .getArray()
-        .find((layer) => {
-          return layer.get("id") === "marker";
-        });
-      if (markerLayer) {
-        markerLayer.setZIndex(10);
-      }
+    //   const markerLayer = this.map
+    //     .getLayers()
+    //     .getArray()
+    //     .find((layer) => {
+    //       return layer.get("id") === "marker";
+    //     });
+    //   if (markerLayer) {
+    //     markerLayer.setZIndex(10);
+    //   }
 
-      // 同时设置高亮图层 zIndex 较低
-      shanxiLayer.setZIndex(1);
-      // -------------【结束】-------------
-      // const targetExtent = [106.8, 34.3, 118.6, 41.2];//山西
-      const targetExtent = [119.65, 40.87, 131.31, 46.30];//吉林
-      this.map.getView().fit(targetExtent, { duration: 2000 });
-    }
+    //   // 同时设置高亮图层 zIndex 较低
+    //   shanxiLayer.setZIndex(1);
+    //   // -------------【结束】-------------
+    //   // const targetExtent = [106.8, 34.3, 118.6, 41.2];//山西
+    //   const targetExtent = [119.65, 40.87, 131.31, 46.30];//吉林
+    //   this.map.getView().fit(targetExtent, { duration: 2000 });
+    // }
     // 这个放在外面
     this.initEvent();
   },

+ 1 - 0
vue.config.js

@@ -134,6 +134,7 @@ module.exports = {
         target: process.env.VUE_APP_downLoadChartAPIPROXY,
         // target: "http://0.0.0.0:3001",
         // target: "http://192.168.50.235:8999/downLoadChart", //内网演示
+           // target: "http://192.168.50.235:8999/downLoadChart", //内网演示  这个是对
         // target: "http://106.120.102.238:28999/downLoadChart", //外网演示
         changeOrigin: true,
         pathRewrite: {