Incubator-echarts: Call to dataView icon from another button

Created on 8 Apr 2019  ·  10Comments  ·  Source: apache/incubator-echarts

What problem does this feature solve?

Hi! I have been woorking with Angular and echarts in a proyect, and a i want to see the dataView table from another button. I read in the API Documentatión that i can call to echarts functions with the dispatch funcition, something like that

this.echartInstance.dispatchAction({ type: 'restore' });

But i cant do what i want with any action or events. Maybe is not possible for now??

I attach two images, the first is what i got now, the dataView icon (with label"A"), and the button (with label"B") what i want to have the same behaviour that the dataView icon.

Captura

The second image show what i got when i press the dataView icon, i want the same bhaviour when i press the another button.

Captura2

Any ideas or advices? Thanks a lot !

What does the proposed API look like?

Maybe something like

echartInstance.dispatchAction({ type: 'show dataView' });

For show and hide the dataView table.


en support

All 10 comments

Hi! We've received your issue and please be patient to get responded. 🎉
The average response time is expected to be within one day for weekdays.

In the meanwhile, please make sure that you have posted enough image to demo your request. You may also check out the API and chart option to get the answer.

Have a nice day! 🍵

Please check http://echarts.apache.org/option.html#toolbox.feature for custom toolbox features.

Please check http://echarts.apache.org/option.html#toolbox.feature for custom toolbox features.

Thanks for the answer! But i want to call a toolbox feature from a button outside echarts (whit the echartInstance), not create a custom feature.

Hi, I need this feature too. I'd like to use

myChart.dispatchAction( type: 'dataView' }

or something similar to open the chart dataView.

This is not working, there isn't a dataView event on documentation either similar event.

How clould open the data view with toolbox no visible?

Can you provide an online demo about what you have done now? http://jsfiddle.net

Yes, i paste the link below

http://jsfiddle.net/8wa3e9cz/2/

Captura

The desire behaviour of the button with label A is show the table with the data, the same table that show the icon with label B

It seems that you are still using ECharts 2, which is not supported any longer. Please try with the latest version, and if there's still a problem with this, just let me know.

I use the latest version in my project, the online demo is only a example of the desire beahviour.

I update the example with the last versión and added some things, trying to explain the more the problem.

http://jsfiddle.net/dv9g4z3u/4/

Hi, I need this feature too. I'd like to use

myChart.dispatchAction( type: 'dataView' }

or something similar to open the chart dataView.

This is not working, there isn't a dataView event on documentation either similar event.

How clould open the data view with toolbox no visible?

I also need this feature.

Was this page helpful?
0 / 5 - 0 ratings

Related issues

jarben picture jarben  ·  3Comments

akvaliya picture akvaliya  ·  3Comments

antorman picture antorman  ·  3Comments

Thinkpad93 picture Thinkpad93  ·  3Comments

liuqz picture liuqz  ·  3Comments