Skip to content

Commit 1ce7f30

Browse files
committed
[update] 1. fix ut
2. 只处理mapbox图层的source。
1 parent c4d853d commit 1ce7f30

1 file changed

Lines changed: 2 additions & 1 deletion

File tree

src/common/mapping/WebMapV3.js

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -486,7 +486,8 @@ export function createWebMapV3Extending(SuperClass, { MapManager, mapRepo, crsMa
486486
});
487487
Object.assign(this._mapResourceInfo, { catalogs });
488488
const mapboxglLayers = layers.filter((layer) => !l7LayerUtil.isL7Layer(layer));
489-
for(const sourceId in sources) {
489+
const mapboxSourceIds = mapboxglLayers.map((layer) => layer.source);
490+
for(const sourceId of mapboxSourceIds) {
490491
const source = sources[sourceId];
491492
if(source.type === 'geojson' && source.data?.type === 'supermap-rest-data') {
492493
source.data = await l7LayerUtil.getRestDataGeojsonByWebMap(source.data, {iportalServiceProxyUrlPrefix: this.options.server, withoutFormatSuffix: true});

0 commit comments

Comments
 (0)