diff --git a/public/static/libs/mapbox/style/floodOneMap.json b/public/static/libs/mapbox/style/floodOneMap.json index 6c9d81e..30d544d 100644 --- a/public/static/libs/mapbox/style/floodOneMap.json +++ b/public/static/libs/mapbox/style/floodOneMap.json @@ -567,12 +567,12 @@ }, { "id": "pipeline_info", - "key": "hubei_xiaogan_pipeline_info", - "source-layer": "hubei_xiaogan_pipeline_info", + "key": "hn_kf_hm_pipeline", + "source-layer": "hn_kf_hm_pipeline", "type": "line", "filter": [ "in", - "layer", + "类型", "" ], "paint": { @@ -580,38 +580,23 @@ "match", [ "get", - "layer" + "类型" ], - "YS", + "ys", "#1b76ff", - "WS", + "ws", "#ff4c61", - "HS", + "hs", "#ff4c61", "#000000" ], - "line-width": [ - "match", - [ - "get", - "data_class" - ], - 1, - 8, - 2, - 6, - 3, - 4, - 4, - 2, - 2 - ] + "line-width": 2 }, "layout": {}, "minzoom": 0, "maxzoom": 24, "mType": "mvt", - "columns": "起点点号,终点点号,layer,data_class,st_asText(geometrys) as geometry" + "columns": "起始点号,连接点号,st_asText(geometrys) as geometry" }, { "id": "city_boundary", @@ -660,12 +645,12 @@ }, { "id": "pipeline_point", - "key": "hubei_xiaogan_pipeline_point", - "source-layer": "hubei_xiaogan_pipeline_point", + "key": "hn_kf_hm_pipeline_point", + "source-layer": "hn_kf_hm_pipeline_point", "type": "symbol", "filter": [ "in", - "图层", + "类型", "" ], "paint": { @@ -676,18 +661,18 @@ "match", [ "get", - "图层" + "类型" ], - "雨水点", + "ys", "ysj", - "污水点", + "ws", "wsj", - "合流点", + "hs", "hsj", "ysbz" ], "icon-size": 0.5, - "text-field": "{起点点号,终点点号}", + "text-field": "{管线点号}", "text-font": [ "Noto Sans CJK SC DemiLight", "Arial Unicode MS Regular" @@ -696,10 +681,10 @@ "text-line-height": 3, "text-anchor": "top" }, - "minzoom": 16, + "minzoom": 1, "maxzoom": 24, "mType": "mvt", - "columns": "设施编码,图层,st_asText(geometrys) as geometry" + "columns": "管线点号,类型,st_asText(geometrys) as geometry" }, { "id": "point", @@ -847,12 +832,12 @@ ], "filter": [ [ - "WS", - "HS" + "ws", + "hs" ], [ - "污水点", - "合流点" + "ws", + "hs" ] ] }, @@ -863,10 +848,10 @@ ], "filter": [ [ - "YS" + "ys" ], [ - "雨水点" + "ys" ] ] }, diff --git a/public/static/libs/mapbox/style/floodOneMap.json b/public/static/libs/mapbox/style/floodOneMap.json index 6c9d81e..30d544d 100644 --- a/public/static/libs/mapbox/style/floodOneMap.json +++ b/public/static/libs/mapbox/style/floodOneMap.json @@ -567,12 +567,12 @@ }, { "id": "pipeline_info", - "key": "hubei_xiaogan_pipeline_info", - "source-layer": "hubei_xiaogan_pipeline_info", + "key": "hn_kf_hm_pipeline", + "source-layer": "hn_kf_hm_pipeline", "type": "line", "filter": [ "in", - "layer", + "类型", "" ], "paint": { @@ -580,38 +580,23 @@ "match", [ "get", - "layer" + "类型" ], - "YS", + "ys", "#1b76ff", - "WS", + "ws", "#ff4c61", - "HS", + "hs", "#ff4c61", "#000000" ], - "line-width": [ - "match", - [ - "get", - "data_class" - ], - 1, - 8, - 2, - 6, - 3, - 4, - 4, - 2, - 2 - ] + "line-width": 2 }, "layout": {}, "minzoom": 0, "maxzoom": 24, "mType": "mvt", - "columns": "起点点号,终点点号,layer,data_class,st_asText(geometrys) as geometry" + "columns": "起始点号,连接点号,st_asText(geometrys) as geometry" }, { "id": "city_boundary", @@ -660,12 +645,12 @@ }, { "id": "pipeline_point", - "key": "hubei_xiaogan_pipeline_point", - "source-layer": "hubei_xiaogan_pipeline_point", + "key": "hn_kf_hm_pipeline_point", + "source-layer": "hn_kf_hm_pipeline_point", "type": "symbol", "filter": [ "in", - "图层", + "类型", "" ], "paint": { @@ -676,18 +661,18 @@ "match", [ "get", - "图层" + "类型" ], - "雨水点", + "ys", "ysj", - "污水点", + "ws", "wsj", - "合流点", + "hs", "hsj", "ysbz" ], "icon-size": 0.5, - "text-field": "{起点点号,终点点号}", + "text-field": "{管线点号}", "text-font": [ "Noto Sans CJK SC DemiLight", "Arial Unicode MS Regular" @@ -696,10 +681,10 @@ "text-line-height": 3, "text-anchor": "top" }, - "minzoom": 16, + "minzoom": 1, "maxzoom": 24, "mType": "mvt", - "columns": "设施编码,图层,st_asText(geometrys) as geometry" + "columns": "管线点号,类型,st_asText(geometrys) as geometry" }, { "id": "point", @@ -847,12 +832,12 @@ ], "filter": [ [ - "WS", - "HS" + "ws", + "hs" ], [ - "污水点", - "合流点" + "ws", + "hs" ] ] }, @@ -863,10 +848,10 @@ ], "filter": [ [ - "YS" + "ys" ], [ - "雨水点" + "ys" ] ] }, diff --git a/src/views/gisMapPage/gisMapBox1.vue b/src/views/gisMapPage/gisMapBox1.vue index 6a1f6c0..1d0da9b 100644 --- a/src/views/gisMapPage/gisMapBox1.vue +++ b/src/views/gisMapPage/gisMapBox1.vue @@ -191,7 +191,7 @@ const setLayerVisible = ({ layername, isCheck }) => { if (!!!window.newfiberMapbox) return; - + console.log('layername---', layername); if (((config || {}).filter || {})[layername]) { config.filter[layername].layerName.forEach((name, index) => { let filter = map.getFilter(name);