diff --git a/src/views/spongePerformance/waterlogging/prevention/index.vue b/src/views/spongePerformance/waterlogging/prevention/index.vue index 651052d..6f07b5a 100644 --- a/src/views/spongePerformance/waterlogging/prevention/index.vue +++ b/src/views/spongePerformance/waterlogging/prevention/index.vue @@ -167,6 +167,7 @@ resultList.value = tableData.value[0].resultList; let moduleGeojson = getFeatureGeojson(tableData.value[0].partitionList); let moduleBoundaryGeojson = getGeojsonBoundary(moduleGeojson); + console.log('moduleGeojson---', moduleGeojson); let modulelabelGeojson = getGeojsonCenter(moduleGeojson); //gis渲染内涝区域 addModuleLayer(moduleGeojson, 'moduleFlood', '#95f204'); @@ -201,7 +202,7 @@ const getGeojsonCenter = geojson => { let features = []; geojson.features.forEach(item => { - let center = turf.center(item.geometry); + let center = turf.center(item); center.properties = item.properties; features.push(center); });