一、需求
HighChart模拟点击series的name显示隐藏,批量操作
二、代码实现
function toggleHighChart(show) {var charts = Highcharts.charts;for(var i in charts){var chart = charts[i];var series = chart.options.series;for(var j in series){if(series[j].in){//自定义属性判断条件if(!show) {chart.series[j].hide();}else{chart.series[j].show();}}}}}