Commit ff223685ed53877c39e03a7bb8e166e0c4f09e0b
1 parent
bc144521
feat(src/packages): 修改地图从中国地图,点击省会下钻,再点击市区,返回只能返回到省会,再返回到中国地图无效
Showing
2 changed files
with
2 additions
and
0 deletions
| ... | ... | @@ -112,6 +112,7 @@ const handleMap3DClick = async (params: any) => { |
| 112 | 112 | saveGeojson.value?.features.forEach((item: any) => { |
| 113 | 113 | if (item.properties.name === name) { |
| 114 | 114 | const level = item.properties.level.toUpperCase() |
| 115 | + if (level === 'DISTRICT') return | |
| 115 | 116 | const adcode = item.properties.adcode |
| 116 | 117 | props.chartConfig.option.mapRegion.adcode = adcode |
| 117 | 118 | saveLevelStr.level = level | ... | ... |
| ... | ... | @@ -308,6 +308,7 @@ const handleVChartClick = async (params: any) => { |
| 308 | 308 | saveGeojson.value?.features.forEach((item: any) => { |
| 309 | 309 | if (item.properties.name === name) { |
| 310 | 310 | const level = item.properties.level.toUpperCase() |
| 311 | + if (level === 'DISTRICT') return | |
| 311 | 312 | const adcode = item.properties.adcode |
| 312 | 313 | props.chartConfig.option.mapRegion.adcode = adcode |
| 313 | 314 | saveLevelStr.level = level | ... | ... |