I have the following datable:
<rich:dataTable id="grid1" value="#{monitorForm.customerList}" var="custRow">
<rich:column width="5">
<h:selectBooleanCheckbox value="#{custRow.selected}">
<a:support event="onclick" action="#{monitorForm.selectOrderLines(custRow)}"
reRender="custTable_#{custRow.id}"/>
</h:selectBooleanCheckbox>
</rich:column>
<rich:subTable id="custTable_#{custRow.id}"
var="row" value="#{custRow.orderList}" rendered="#{custRow.show}">
<rich:column width="5">
<h:selectBooleanCheckbox value="#{row.checked}" />
</rich:column>
<rich:column>
<h:outputText value="#{row.name}" />
</rich:column>
</rich:subTable>
</rich:dataTable>
When I click on the checkbox the action #{monitorForm.selectOrderLines(custRow)}
sets the checkboxes for the selected customer and I want only the subtable for that customer to be reRendered.
The above does not work.
The error is [AjaxContext] Target component for id custTable_<id number> does not exist.
Everything works fine when I use reRender="grid1"
but that can be very slow when there are many rows.
Is it possible to have rich:subTable with a dynamic id that I can use for reRendering only that subTable?