I am using PrimeFaces 6.1 ( Mojarra JSF 2.2.6, Tomcat server) and I have a datatable with virtual scrolling.
In each row, I have a checkbox with an ajax event that executes a listener method from a bean.
It works properly without virtual scrolling, even with live scrolling (On Demand scrolling).
If I activate virtual scrolling, it works for the rows that are shown in the begining, but NOT for the new rows that are shown after I scroll down. It still works if I scroll up again and click the checkboxes from the first rows.
I don't know if it is a bug of PrimeFaces, or it's me who is doing something wrong. I would appreciate any help to fix the problema, or to get information that can help fixing it.
The datatable:
Code: Select all
<h:form id="ttForm">
<p:dataTable id="dataTableId"
value="#{someBean.dataList}"
var="node"
rowIndexVar="rowIndex"
resizableColumns="true"
scrollRows="20"
scrollable="true"
virtualScroll="true"
scrollHeight="100"
rows="20">
(... some columns...)
<p:column>
<h:panelGroup id="column1">
<h:selectBooleanCheckbox value="#{node.managed}">
<p:ajax
event="change"
listener="#{someBean.executeManagedAction()}"
process="@this"
partialSubmit="true" />
</h:selectBooleanCheckbox>
</h:panelGroup>
</p:column>
</p:dataTable>
</h:form>
Please let me know if you need more information.
Thanks in advance ,