// JSON
$.getJSON('./json/shandong.json', function (data) {
echarts.registerMap('shandong', data);
var chart = echarts.init(document.getElementById('map'));
var option = {
backgroundColor: '#404a59',
title: {
text: '山东地图',
color:"#fff"
visualMap: {
show:false,
left: 'right',
categories: ['1',],
inRange: {
color: ['#f46d43']
text:['High','Low'], // 文本,默认为数值文本
calculable: true
series: [{
type: 'map',
map: 'shandong',
data:data11,
aspectScale:1,//保持原始比例
roam: true,
label: {
show:true,
normal: {
show: true,
color:"#fff",
emphasis: {
show: true,
fontSize:16,
color:"#fff"
itemStyle: {
normal: {
areaColor: '#323c48',
borderColor: '#111'
emphasis: {//鼠标移入高亮显颜色
areaColor: '#f46d43'
chart.setOption(option);
chart.on('click', function(params){
console.log(params);//此处写点击事件内容
for(var i=0;i