Board index JavaServer Faces General Datatable update attribute not working

Datatable update attribute not working

Components, Ajax Framework, Utilities and More.


Posts: 11
I am working with a datatable in version 2.2.RC1 and cannot seem to get the update attribute to work. I have tried most of the formats for the value of the parameter such as "formName:resultCount", ":resultCount","resultCount", but none seem to work. Is there an issue around this attribute in 2.2.RC1?

<h:panelGroup id="resultCount">
<h:outputText value="Event Result Sets : #{deepWebHarvestsBean.harvestsBean.resultCount}" styleClass="resultLabel"> </h:outputText>
</h:panelGroup>
<p:dataTable id="resultsTable" var="harvest" value="#{deepWebHarvestsBean.lazyModel}" page="#{deepWebHarvestsBean.resultPage}" dynamic="true" lazy="true"
paginator="true" rows="17" emptyMessage="No Harvest Results" update="resultCount">


<p:column style="width:5px;text-align:center;">
<f:facet name="header">
</f:facet>

<h:commandButton styleClass="buttons" image="images/invalid.png" onclick="showWaitCursor();" action="#{deepWebHarvestsBean.validateHarvest}"
rendered='#{harvest.deleted == "T"}' title="Validate Harvest">
<f:param name="harvestId" value="#{harvest.harvestID}"/>
</h:commandButton>

<h:commandButton styleClass="buttons" image="images/valid.png" onclick="showWaitCursor();" action="#{deepWebHarvestsBean.invalidateHarvest}"
rendered='#{harvest.deleted != "T"}' title="Invalidate Harvest">
<f:param name="harvestId" value="#{harvest.harvestID}"/>
</h:commandButton>

</p:column>

</p:dataTable>


Posts: 723
Location: United States
The update attribute is for row selection. So you want to display the resultCount each time the user selects a row in the dataTable?


Posts: 11
Actually I was looking to update resultCount every time I reload the table with lazy data. I have tried embedding an ajax tag in the dataTable but it doesn't like that at runtime. Thanks for the reply!


Return to General