Hi,
I have the following class:
@Scope(ScopeType.APPLICATION) public class EXAccessPoint { ... @DataModel private List<EntryExit> currentAlerts; @DataModelSelectionIndex private int alertIndex; ... public void actionAlert() { log.info("actionAlert():alertIndex=" + alertIndex); alerts.remove(alertIndex); calculateAlerts(); }
<h:dataTable value="#{entryGate.currentAlerts}" var="alert"> <h:column> <f:facet name="header">Alert</f:facet> <h:commandLink action="#{entryGate.actionAlert}">#{alert.message}"</h:commandLink> </h:column> </h:dataTable>
Try
<h:dataTable value="#{currentAlerts}" var="alert">