There are several related questions on this topic about SO and elsewhere , but I could not find a definitive answer to this specific question.
I have p:dataTable, and I want to click on the line and open the details page (a new page, not a dialog or window).
I solved it this way (that I have from the perffaces website, for some reason it no longer exists: http://web.archive.org/web/20101001223235/http://www.primefaces.org/showcase/ui /datatableRowSelectionInstant.jsf ):
<p:dataTable var="order" value="#{orderBean.orders}" selection="#{orderBean.selectedOrder}" selectionMode="single" rowKey="#{order.number}">
<p:ajax event="rowSelect" listener="#{orderBean.orderSelect}"/>
<p:column ... />
</p:dataTable>
Navigation is then done in a bean:
public void orderSelect(SelectEvent event) {
ConfigurableNavigationHandler nh = (ConfigurableNavigationHandler)FacesContext.getCurrentInstance().getApplication().getNavigationHandler();
nh.performNavigation("orderDetail?faces-redirect=true");
}
My question is: is there a way to do this only inside JSF without bean support?
, exmaple perffaces, , - .