全国json数据获取地址:
https://github.com/lyhmyd1211/GeoMapData_CN
单独区域json数据获取地址:
http://datav.aliyun.com/tools/atlas/#&lat=31.769817845138945&lng=104.29901249999999&zoom=4
利用echarts通过获取的json文件绘制所需地图
代码示例:
renderMap (map, data) {
let chart = $echarts.init(document.getElementById('mainTwo'));
this.option.dataRange = {
x: '10%',
y: '8%',
splitList: this.arr,
show:this.areaStatMax>0?true:false,
color: ['#E0022B', '#E09107', '#A3E00B'],
textStyle: {
color:'#fff',
fontSize: 11
}
}
this.option.series = [