Skip to content

Commit ac9e78c

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

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
@@ -433,7 +433,8 @@ export function createWebMapV3Extending(SuperClass, { MapManager, mapRepo, crsMa
433433
});
434434
Object.assign(this._mapResourceInfo, { catalogs });
435435
const mapboxglLayers = layers.filter((layer) => !l7LayerUtil.isL7Layer(layer));
436-
for(const sourceId in sources) {
436+
const mapboxSourceIds = mapboxglLayers.map((layer) => layer.source);
437+
for(const sourceId of mapboxSourceIds) {
437438
const source = sources[sourceId];
438439
if(source.type === 'geojson' && source.data?.type === 'supermap-rest-data') {
439440
source.data = await l7LayerUtil.getRestDataGeojsonByWebMap(source.data, {iportalServiceProxyUrlPrefix: this.options.server, withoutFormatSuffix: true});

0 commit comments

Comments
 (0)