ok I am trying to use the f:param here to pass the requestid as parameter to the review page. Currently am doing it as shown below but managedproperty is not working as I want because I need to post again from review.xhtml. How can i add this f:param tag and then handle it in bean?
<p:dataTable style="width:50px;" id="requestList" value="#
{requestBean.requestsList}" var="requestClass">
<p:column>
<f:facet name="header">
<h:outputText value="ID" />
</f:facet>
<a href="review.xhtml?id=#{requestClass.requestID}">
<h:outputText value="#{requestClass.requestID}" />
</a>
</p:column>
<p:column>
<f:facet name="header">
<h:outputText value="Status" />
</f:facet>
<h:outputText value="#{requestClass.requestStatus}" />
</p:column>
<p:column>
<f:facet name="header">
<h:outputText value="Details" />
</f:facet>
<h:outputText value="#{requestClass.requestTitle}" />
</p:column>
</p:dataTable>
Thanks
I think you can try the following:
. Keep your bean as RequestScoped and put a hidden field in your form in review.xhtml to contain the id:
. Keep your bean as RequestScoped and put a
<f:param>inside the commandButton in review.xhtml:. Change you bean to ViewScoped