在自己项目中做省份地图时,可以显示出北京、天津、湖北、浙江地方的地图,但是河北省的地图显示不了,为什么会这样?有人和我碰到同样的问题吗?
配置项如下
function initchartForJson(){
var hebei = '${contextPath}/Chart/echarts-master/map/json/province/hebei.json';
//var beijing = '${contextPath}/Chart/echarts-master/map/json/province/beijing.json';
$.get(hebei, function(mapJson) {
$("#loadmap").css("display","block");
echarts.registerMap('河北', mapJson);
var myChart = echarts.init(document.getElementById('loadmap'));
option={
visualMap: {
min: 0,
max: 3000,
left: 'left',
top: 'bottom',
text: ['高', '低'],
calculable: true,
colorLightness: [0.2, 100],
color: ['#c05050','#e5cf0d','#5ab1ef'],
dimension: 0
},
series : [
{
//name : '生产总值',
type : 'map',
//map的值也是,省份汉语名称
map : '河北',
label: {
normal: {
show: true
},
emphasis: {
show: true
}
}
}
]
}
myChart.setOption(option);
});
}