interose
2 Apr 2012, 4:57 AM
Hi,
I'm looking for a basic approach to display a set of data either as grid or as chart. It's up to the user which presentation he prefers.
I have a tab panel which has three static tabs. Each tab displays a grid. So far this was no problem at all. Now I want to display a chart instead of the grid. It's also no problem to create an additional tab with a chart which is linked to a store. But I want to toggle between chart and grid at runtime via a button.
So my question is if it is possible to toggle the presentation (grid vs. chart) within a tab panel?
I've searched around and found a former plugin RemoteComponent which makes it possible to load a component via Ajax. So then it would be possible to load the tab content via ajax and change the tab content. E.g. by clicking a toolbar button. But unfortunately this plugin is only for extjs 3.x and 2.x.
According to this thread (http://www.sencha.com/forum/showthread.php?22684-quot-Autoload-quot-for-the-Items-of-a-FormPanel/page3) using the option script: true with autoloading is not a good option. As mentioned, a better way is to write his own renderer which then executes the ext javascript.
So maybe someone has faced a similar problem. Thanks in advance - Marcus.
I'm looking for a basic approach to display a set of data either as grid or as chart. It's up to the user which presentation he prefers.
I have a tab panel which has three static tabs. Each tab displays a grid. So far this was no problem at all. Now I want to display a chart instead of the grid. It's also no problem to create an additional tab with a chart which is linked to a store. But I want to toggle between chart and grid at runtime via a button.
So my question is if it is possible to toggle the presentation (grid vs. chart) within a tab panel?
I've searched around and found a former plugin RemoteComponent which makes it possible to load a component via Ajax. So then it would be possible to load the tab content via ajax and change the tab content. E.g. by clicking a toolbar button. But unfortunately this plugin is only for extjs 3.x and 2.x.
According to this thread (http://www.sencha.com/forum/showthread.php?22684-quot-Autoload-quot-for-the-Items-of-a-FormPanel/page3) using the option script: true with autoloading is not a good option. As mentioned, a better way is to write his own renderer which then executes the ext javascript.
So maybe someone has faced a similar problem. Thanks in advance - Marcus.