【发布时间】:2013-05-11 22:37:52
【问题描述】:
错误代码是:
<h:form id="search_form">
<h:commandButton class="button" value="View" action="#{InfoBean.search}">
<f:ajax execute="search_form" render="linear1"></f:ajax>
<f:ajax execute="search_form" render="linear2"></f:ajax>
</h:commandButton>
<p:lineChart id="linear1" value="#{InfoBean.linearModel1}" legendPosition="e"/>
<p:lineChart id="linear2" value="#{InfoBean.linearModel2}" legendPosition="e"/>
</h:form>
我想要做的是当我点击commandButton 时,我想刷新这两个图表。但是现在我使用了两个<ajax>标签,其中第二个不起作用。
那么如何使用ajax来渲染两个图表呢?
【问题讨论】:
标签: ajax jsf jsf-2 commandbutton