Skip to content

Commit 791f1e9

Browse files
committed
【bug】webmap改变restdata服务上图生成mvt的默认样式颜色
(reviewed by chengl)
1 parent b8645e9 commit 791f1e9

File tree

1 file changed

+4
-4
lines changed

1 file changed

+4
-4
lines changed

src/openlayers/mapping/WebMap.js

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -36,7 +36,7 @@ const MAX_MIGRATION_ANIMATION_COUNT = 1000;
3636
* @param {string} [options.target='map'] - 地图容器id。
3737
* @param {string} [options.server="http://www.supermapol.com"] - 地图的地址。
3838
* @param {function} [options.successCallback] - 成功加载地图后调用的函数。
39-
* @param {function} [options.errorCallback] - 加载地图失败
39+
* @param {function} [options.errorCallback] - 加载地图失败调用的函数
4040
* @param {string} [options.credentialKey] - 凭证密钥。
4141
* @param {string} [options.credentialValue] - 凭证值。
4242
* @param {boolean} [options.withCredentials=false] - 请求是否携带 cookie。
@@ -1703,7 +1703,7 @@ export class WebMap extends ol.Observable {
17031703
getDataVectorTileStyle(featureType) {
17041704
let styleParameters = {
17051705
radius: 8, //圆点半径
1706-
fillColor: '#0083cb', //填充色
1706+
fillColor: '#EE4D5A', //填充色
17071707
fillOpacity: 0.9,
17081708
strokeColor: '#ffffff', //边框颜色
17091709
strokeWidth: 1,
@@ -1712,10 +1712,10 @@ export class WebMap extends ol.Observable {
17121712
type: "BASIC_POINT"
17131713
};
17141714
if(["LINE", "LINESTRING", "MULTILINESTRING"].includes(featureType)){
1715-
styleParameters.strokeColor = '#0083cb';
1715+
styleParameters.strokeColor = '#4CC8A3';
17161716
styleParameters.strokeWidth = 2;
17171717
}else if(["REGION", "POLYGON", "MULTIPOLYGON"].includes(featureType)){
1718-
styleParameters.fillColor = '#0083cb';
1718+
styleParameters.fillColor = '#826DBA';
17191719
}
17201720
return styleParameters;
17211721
}

0 commit comments

Comments
 (0)