Quellcode durchsuchen

首页地图缩放调整

Bella vor 2 Jahren
Ursprung
Commit
360f564010
4 geänderte Dateien mit 34 neuen und 35 gelöschten Zeilen
  1. 14 14
      public/static/config/config.js
  2. 6 6
      src/components/map/MapHolder.vue
  3. 1 1
      src/views/HomeView.vue
  4. 13 14
      vue.config.js

+ 14 - 14
public/static/config/config.js

@@ -14,7 +14,7 @@ var systemConfig = {
   assetsUrl: "http://localhost:2013",
   mapViewer: {
     center: [31.14785322514787, 121.50195320451814],
-    zoom: 2,
+    zoom: 0,
   },
   terrainMap: {
     url: "http://aimap.pudong.sh:5236/zjmap/reproduction-service/maps/rest/services/dlg-fullcolor/proxy?AccessKey=lUaEMxqqhZKLSImGuP/Ergx47orYVyIqHVgxfyGpIurKAy9kdq5uU1cWuTuIXeOM",
@@ -55,22 +55,22 @@ var systemConfig = {
     // url: "http://aimap.pudong.sh:5236/zjmap/reproduction-service/maps/rest/services/admin-pudong-sh2k-neighborhood/mapserver?AccessKey=lUaEMxqqhZKLSImGuP/Ergx47orYVyIqHVgxfyGpIurKAy9kdq5uU1cWuTuIXeOM",
 
     // 按照宝石蓝底图分辨率
-    resolutions: [
-      529.1666666666666,264.5833333333333,132.29166666666666, 52.916666666666664, 26.458333333333332,
-      13.229166666666666, 5.291666666666666, 2.645833333333333,
-      1.3229166666666665, 0.5291666666666666, 0.2645833333333333,
-      0.13229166666666664,
-    ],
+    // resolutions: [
+    //   529.1666666666666,264.5833333333333,132.29166666666666, 52.916666666666664, 26.458333333333332,
+    //   13.229166666666666, 5.291666666666666, 2.645833333333333,
+    //   1.3229166666666665, 0.5291666666666666, 0.2645833333333333,
+    //   0.13229166666666664,
+    // ],
     //
     //529.167725002116, 264.583862501058
     // 按照测绘院分辨率虚拟的
-    // resolutions: [
-    //   132.2919312505292, 52.91677250021167, 26.458386250105836,
-    //   13.229193125052918, 5.291677250021167, 2.6458386250105836,
-    //   1.3229193125052918, 0.5291677250021167, 0.26458386250105836,
-    //   0.13229193125052918, 0.0529167725002, 0.0264583862501, 0.0132291931251,
-    //   0.00529167725, 0.002645838625, 0.0013229193125,
-    // ],
+    resolutions: [
+      132.2919312505292, 52.91677250021167, 26.458386250105836,
+      13.229193125052918, 5.291677250021167, 2.6458386250105836,
+      1.3229193125052918, 0.5291677250021167, 0.26458386250105836,
+      0.13229193125052918, 0.0529167725002, 0.0264583862501, 0.0132291931251,
+      0.00529167725, 0.002645838625, 0.0013229193125,
+    ],
     minZoom: 0,
     maxZoom: 14,
   },

+ 6 - 6
src/components/map/MapHolder.vue

@@ -666,7 +666,7 @@ export default {
 
       map2DViewer.map = L.map("map2DViewer", {
         crs: crs,
-        zoom: 2,
+        zoom: 0,
         minZoom: systemConfig.imageryLayer.minZoom,
         maxZoom: systemConfig.imageryLayer.maxZoom,
         attributionControl: false,
@@ -1132,12 +1132,12 @@ export default {
 <style lang="less" scoped>
 #map2DViewer {
   position: absolute;
-  width: 140%;
-  height: calc(147% - 2px);
+  width: 200vw;
+  height: 200vh;
   background-color: rgb(0, 47, 71);
   z-index: 1;
-  top: -220px;
-  left: -400px;
-  scale: 0.62;
+  top: -50vh;
+  left: -50vw;
+  transform:scale(0.62);
 }
 </style>

+ 1 - 1
src/views/HomeView.vue

@@ -515,7 +515,7 @@ export default {
   height: 100%;
   box-sizing: border-box;
   overflow: hidden;
-  background-color: rgb(0, 47, 71);
+  // background-color: rgb(0, 47, 71);
 }
 /* 镇域专题 */
 #TownContainer {

+ 13 - 14
vue.config.js

@@ -71,31 +71,30 @@ module.exports = {
       //   target: "http://117.131.26.69:10081",
       //   changeOrigin: true, // 允许跨域
       //   pathRewrite: {
-      //     "^/oauth": "/proxy_oauth"
-      //   }
+      //     "^/oauth": "/proxy_oauth",
+      //   },
       // },
       // "/dms": {
       //   target: "http://117.131.26.69:10081",
       //   changeOrigin: true, // 允许跨域
       //   pathRewrite: {
-      //     "^/dms": "/proxy_dms"
-      //   }
+      //     "^/dms": "/proxy_dms",
+      //   },
       // },
       // "/conllection": {
       //   target: "http://117.131.26.69:10081",
       //   changeOrigin: true, // 允许跨域
       //   pathRewrite: {
-      //     "^/conllection": "/proxy_conllection"
-      //   }
+      //     "^/conllection": "/proxy_conllection",
+      //   },
       // },
-      // "/audit": {
-      //   target: "http://117.131.26.69:10081",
-      //   changeOrigin: true, // 允许跨域
-      //   pathRewrite: {
-      //     "^/audit": "/proxy_audit"
-      //   }
-      // },
-
+      "/audit": {
+        target: "http://117.131.26.69:10081",
+        changeOrigin: true, // 允许跨域
+        pathRewrite: {
+          "^/audit": "/proxy_audit",
+        },
+      },
       "/oauth": {
         target: "http://10.220.106.75:10011",
         changeOrigin: true, // 允许跨域