I have already posted this on stackoverflow[1] but did not get any response so here goes again:
I am having troubles using commandbutton in a treetable. The events are triggered correctly for the root elements in the tree, however any child elemts do not work.
TreeTable:
Code: Select all
<p:treeTable var="ou"
value="#{oumanagement.ouTree}"
class="userList"
id="outable"
selectionMode="single">
<f:facet name="header">
<h:outputText value="List of Organisational Units" />
</f:facet>
<p:column headerText="Organisational Unit" >
<h:outputText value="#{ou.name}" />
</p:column>
<p:column>
<p:commandButton action="#{oumanagement.remove(ou.id)}" icon="fa fa-trash-o" update=":ouform:outable :ouform:msgs" transient="true">
<p:confirm header="Are You Sure" message="Are you sure?" icon="ui-icon-alert" />
</p:commandButton>
</p:column>
<p:column>
<p:commandButton action="#{oumanagement.viewDetails(ou.id)}" icon="fa fa-sliders" transient="true" ajax="false"/>
</p:column>
</p:treeTable>
Code: Select all
public String viewDetails(int id) {
activeOU = ouService.find(id);
FacesContext.getCurrentInstance().getExternalContext().getFlash().put("ou", activeOU);
return "/pages/secure/organisationManagement/details";
}
Any help is greatly appreciated.
PF version: 5.1
Using Spring-faces 2.4.1, jsf-api 2.2.10, jsf-imp 2.2.10
[1]: http://stackoverflow.com/questions/2921 ... ot-invoked