如何使用ajax在jsf primefaces面板中显示managedbean返回的页面 带素数面的jsf
我试图将页面作为从托管bean返回的字符串获取,该字符串在faces-config.xml中按照导航规则进行配置,现在在jsf primefaces index.xhtml页面中,我使用ajax调用在特定面板中呈现输出页面,但没有在面板中获取页面,而只是导航..那么如何解决这个问题呢?请帮助 提前感谢。如何使用ajax在jsf primefaces面板中显示managedbean返回的页面 带素数面的jsf,ajax,jsf-2,primefaces,Ajax,Jsf 2,Primefaces,我试图将页面作为从托管bean返回的字符串获取,该字符串在faces-config.xml中按照导航规则进行配置,现在在jsf primefaces index.xhtml页面中,我使用ajax调用在特定面板中呈现输出页面,但没有在面板中获取页面,而只是导航..那么如何解决这个问题呢?请帮助 提前感谢。 <h:form> <p:commandButton action="#{bean.setPage('page1')}" process="@this"
<h:form>
<p:commandButton action="#{bean.setPage('page1')}" process="@this"
update="panel" value="show page 1"/>
<p:commandButton action="#{bean.setPage('page2')}" process="@this"
update="panel" value="show page 2"/>
<p:panel id="panel" header="dynamic page include">
<h:panelGroup rendered="#{!empty bean.page}">
<ui:include src="/WEB-INF/fragments/#{bean.page}.xhtml"/>
</h:panelGroup>
</p:panel>
</h:form>