3 Replies Last post: Aug 14, 2008 5:25 PM by Ilya Musihin  
Ludovic Simon   35 posts since
Jun 7, 2007
Currently Being Moderated

Aug 7, 2008 11:12 AM

Chart data is loaded in an unselected tabbedPaneItem

 

 

 

Hello,

 

 

I use a q:chart in a tabbedPaneItem and the chartModel is loaded even if the tabbedPaneItem is never selected.

 

 

In my JSF page (in a q:tabbedPaneItem):

 

 

<q:chart width="400" height="300"

model="#{myBean.chartModel}"

style="background: #fff" view="pie" >

<q:chartNoDataMessage text="No data" />

</q:chart>

 

 

In my bean :

 

 

public ChartModel getChartModel(){

System.out.println("LOADING CHART MODEL");

HashMap<String, Double> data = new HashMap<String, Double>();

data.put("part 1", 20.0);

data.put("part 2", 40.0);

data.put("part 3", 80.0);

PlainModelImpl model = new PlainModelImpl();

PlainSeriesImpl series = new PlainSeriesImpl();

series.setData(data);

series.setId("Test Chart");

model.addSeries(series);

return model;

}

 

 

When my page displays, the getChartModel() is called.

 

 

This problem impact the performance of my application. I use quipukit1.5, myfaces1.1.4 and Tomcat.

 

 

 

Regards,

 

 

Ludovic

 

 

Ilya Musihin TeamDev Ltd. 38 posts since
May 22, 2008
Currently Being Moderated
1. Aug 13, 2008 5:30 PM in response to: Ludovic Simon
Re: Chart data is loaded in an unselected tabbedPaneItem

Hello Ludovic,

 

According to the documentation if attribute loadingMode of the tag q:tabbedPane is set to client, then content of all tabs loads when the page loads. To delay tab content loading you can use server or ajax loading mode. In this case the contents of the appropriate tab will only be loaded when the user switches to that tab.

 

Please contact us if you have any questions.

 

Sincerely,

Ilya Musihin

Ilya Musihin TeamDev Ltd. 38 posts since
May 22, 2008
Currently Being Moderated
3. Aug 14, 2008 5:25 PM in response to: Ludovic Simon
Re: Chart data is loaded in an unselected tabbedPaneItem

Hello Ludovic,

 

We have investigated information that you provided. That was a bug in our Chart implementation and the fix will be available in the next release.

If you need a prerelease version with this fix, please contact quipukit-support AT teamdev DOT com

 

Sincerely,

Ilya Musihin

More Like This

  • Retrieving data ...