Closed tudou167 closed 4 years ago
echarts4.0.2里myChart.on()不能获取顶部分类的返回 线与节点皆没有问题 console.log(myChart) 里找不到顶部分类的对象
myChart.on() 能触发分类并返回参数 或者能获取对象绑定事件
categories: [{ name: periods[0], itemStyle: { normal: { color: periodsColor[0], } } }, { name: periods[1], itemStyle: { normal: { color: periodsColor[1], } } }, { name: periods[2], itemStyle: { normal: { color: periodsColor[2], } } }, { name: '测试', itemStyle: { normal: { color: periodsColor[2], } } }],
### Other comments [其他信息] <!-- For example: Screenshot or Online demo --> <!-- [例如,截图或线上实例 (JSFiddle/JSBin/Codepen)] --> myChart.on('click', function (params) { //console.log(myChart); //console.log(params); });
This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions.
One-line summary [问题简述]
echarts4.0.2里myChart.on()不能获取顶部分类的返回 线与节点皆没有问题 console.log(myChart) 里找不到顶部分类的对象
Version & Environment [版本及环境]
Expected behaviour [期望结果]
myChart.on() 能触发分类并返回参数 或者能获取对象绑定事件
ECharts option [ECharts配置项]