diff --git a/src/components/map/fssm-map.vue b/src/components/map/fssm-map.vue index a37e54c..37e2103 100644 --- a/src/components/map/fssm-map.vue +++ b/src/components/map/fssm-map.vue @@ -2,7 +2,7 @@ * @Author: SunTao 328867980@qq.com * @Date: 2024-10-14 10:46:23 * @LastEditors: SunTao 328867980@qq.com - * @LastEditTime: 2024-12-09 15:13:56 + * @LastEditTime: 2024-12-12 09:21:59 * @FilePath: \znxjxt-ui\src\components\map\fssm-map.vue * @Description: 公共地图 --> @@ -263,22 +263,34 @@ export default { * @return {*} */ initMap() { - const tianditu_vec_c = new TileLayer({ - className: "baseLayerClass", - title: "矢量底图", - id: "vec_c", - source: new XYZ({ - url: "http://10.60.5.242:25033/v3/tile?lang=zh_cn&size=1&scale=1&style=8&x={x}&y={y}&z={z}", - // projection: "EPSG:4326", - }), - visible: true, - }); + // 内网 + // const tianditu_vec_c = new TileLayer({ + // className: "baseLayerClass", + // title: "矢量底图", + // id: "vec_c", + // source: new XYZ({ + // url: "http://10.60.5.242:25033/v3/tile?lang=zh_cn&size=1&scale=1&style=8&x={x}&y={y}&z={z}", + // // projection: "EPSG:4326", + // }), + // visible: true, + // }); + // const tianditu_cva_c = new TileLayer({ + // className: "baseLayerClass", + // title: "矢量地图", + // id: "cva_c", + // source: new XYZ({ + // url: "http://10.60.5.242:25003/v3/tile?lang=zh_cn&size=1&scale=1&style=8&x={x}&y={y}&z={z}", + // // projection: "EPSG:4326", + // }), + // visible: true, + // }); + // 外网 const tianditu_cva_c = new TileLayer({ className: "baseLayerClass", title: "矢量地图", id: "cva_c", source: new XYZ({ - url: "http://10.60.5.242:25003/v3/tile?lang=zh_cn&size=1&scale=1&style=8&x={x}&y={y}&z={z}", + url: "https://webrd0{1-4}.is.autonavi.com/appmaptile?lang=zh_cn&size=1&scale=1&style=8&x={x}&y={y}&z={z}", // projection: "EPSG:4326", }), visible: true, @@ -306,7 +318,10 @@ export default { minZoom: 7, maxZoom: 18, }), - layers: [tianditu_cva_c, tianditu_vec_c, tianditu_img_c], + // 内网 + // layers: [tianditu_cva_c, tianditu_vec_c, tianditu_img_c], + // 外网 + layers: [tianditu_cva_c, tianditu_img_c], }); // 图层点击事件 map.on("singleclick", (e) => { diff --git a/src/main.js b/src/main.js index 4842201..be89124 100644 --- a/src/main.js +++ b/src/main.js @@ -105,7 +105,12 @@ store.watch( () => store.getters.token, (newToken) => { if (newToken) { + // 本地 wsService.connect(`ws://localhost:8080/websocket?token=${newToken}`); + // 内网 + // wsService.connect(`ws://10.60.5.83:8080/websocket?token=${newToken}`); + // 外网 + // wsService.connect(`ws://61.161.250.206:18080/websocket?token=${newToken}`); } }, { immediate: true } diff --git a/src/views/big-screen/index.vue b/src/views/big-screen/index.vue index 7d9e769..df9a579 100644 --- a/src/views/big-screen/index.vue +++ b/src/views/big-screen/index.vue @@ -1576,6 +1576,12 @@ export default { } } + // 内网不需要 外网需要 + ::v-deep .baseLayerClass { + filter: grayscale(200%) invert(200%) sepia(50%) hue-rotate(175deg) + brightness(80%) saturate(550%); + } + } } diff --git a/src/views/big-screen/overview-components/components/inspection-follow.vue b/src/views/big-screen/overview-components/components/inspection-follow.vue index 3a92531..efe6aae 100644 --- a/src/views/big-screen/overview-components/components/inspection-follow.vue +++ b/src/views/big-screen/overview-components/components/inspection-follow.vue @@ -232,6 +232,7 @@ export default { width: 100%; height: 45rem; + // 内网不需要 ::v-deep .baseLayerClass { filter: grayscale(200%) invert(200%) sepia(50%) hue-rotate(175deg) brightness(80%) saturate(550%); diff --git a/src/views/xj/parameter/index.vue b/src/views/xj/parameter/index.vue index 4c942c6..66bc38f 100644 --- a/src/views/xj/parameter/index.vue +++ b/src/views/xj/parameter/index.vue @@ -2,7 +2,7 @@ * @Author: SunTao 328867980@qq.com * @Date: 2024-10-09 13:11:56 * @LastEditors: SunTao 328867980@qq.com - * @LastEditTime: 2024-12-10 10:43:06 + * @LastEditTime: 2024-12-12 09:42:38 * @FilePath: \znxjxt-ui\src\views\xj\parameter\index.vue * @Description: 系统工具-系统参数 --> @@ -11,46 +11,18 @@
- + - + - + - + - 保存 + 保存
@@ -175,7 +147,7 @@ export default { handleQuery() { this.$refs["parameterForm"].validate((valid) => { if (valid) { - updateMapInfo(this.parameterForm).then((res) => {}); + updateMapInfo(this.parameterForm).then((res) => { }); } }); }, @@ -194,6 +166,20 @@ export default { projection: "EPSG:4326", }), layers: [ + //内网 + // new TileLayer({ + // source: new XYZ({ + // url: "http://10.60.5.242:25003/v3/tile?lang=zh_cn&size=1&scale=1&style=8&x={x}&y={y}&z={z}", + // // projection: "EPSG:4326", + // }), + // }), + // new TileLayer({ + // source: new XYZ({ + // url: "http://10.60.5.242:25033/v3/tile?lang=zh_cn&size=1&scale=1&style=8&x={x}&y={y}&z={z}", + // // projection: "EPSG:4326", + // }), + // }), + // 外网 new TileLayer({ source: new XYZ({ url: "https://webrd0{1-4}.is.autonavi.com/appmaptile?lang=zh_cn&size=1&scale=1&style=8&x={x}&y={y}&z={z}", @@ -201,19 +187,19 @@ export default { }), }), // 添加GeoJSON图层 - new VectorLayer({ - source: new VectorSource({ - // url: "http://localhost:8080/defectfile/output.geojson", // GeoJSON文件路径 - url: "", // GeoJSON文件路径 - format: new GeoJSON(), - }), - style: new Style({ - stroke: new Stroke({ - color: "#ff0000", - width: 2, - }), - }), - }), + // new VectorLayer({ + // source: new VectorSource({ + // // url: "http://localhost:8080/defectfile/output.geojson", // GeoJSON文件路径 + // url: "", // GeoJSON文件路径 + // format: new GeoJSON(), + // }), + // style: new Style({ + // stroke: new Stroke({ + // color: "#ff0000", + // width: 2, + // }), + // }), + // }), ], }); this.map = map; @@ -324,5 +310,4 @@ export default { // ::v-deep .ol-layer:nth-child(1) { // filter: invert(100%) hue-rotate(180deg); -// } - +// } diff --git a/vue.config.js b/vue.config.js index 6565301..90fb436 100644 --- a/vue.config.js +++ b/vue.config.js @@ -35,6 +35,10 @@ module.exports = { proxy: { // detail: https://cli.vuejs.org/config/#devserver-proxy [process.env.VUE_APP_BASE_API]: { + // 外网 + // target: `http://61.161.250.206:18080`, + // 内网 + // target: `http://10.60.5.83:8080`, // target: `http://192.168.1.188:8080`, target: `http://localhost:8080`, changeOrigin: true,