Btista commented on issue #4125: 如何在legend中显示value值? URL: https://github.com/apache/incubator-echarts/issues/4125#issuecomment-421220755 不过我找了一种新思路,分享给需要的人: 因为问题的关键在于formatter回调函数里取不到value, 但是echarts提供的api里可以通过echartsInstance.getOption 得到option配置,则可以顺着拿到echartsInstance.getOption().series[0].data , 完了再通过这个回调函数里能取到的name来遍历echartsInstance.getOption().series[0].data最终取到value。 虽然比较绕,但是也能最后拿到哈
---------------------------------------------------------------- This is an automated message from the Apache Git Service. To respond to the message, please log on GitHub and use the URL above to go to the specific comment. For queries about this service, please contact Infrastructure at: [email protected] With regards, Apache Git Services --------------------------------------------------------------------- To unsubscribe, e-mail: [email protected] For additional commands, e-mail: [email protected]
