Hello,

could somebody please explain me, how I can accomplish an update of the values from within a nested DataTable? The Table is populated with a Collection of ArraysLists containing the objects to be updatable,

The DataTable should look like as follows:

<h:form>
<h:dataTable value="#{student.skills}" var="index">
<h:column>
<h:dataTable value="#{index}" var="skillIndex"
rendered="#{not empty index}" headerClass="datatableHeader">
<h:column>
<h:outputText value="#{skillIndex.skill.name}"/>
</h:column>
<h:column>
<h:selectOneMenu id="lvl" required="true"
value="#{skillIndex.level}" ><!-- To be updated! -->
<f:selectItems value="#{res.skilllevels}" /> </h:selectOneMenu>
</h:column>
</h:dataTable>
</h:column>
</h:dataTable>
<h:commandButton type="submit" value="Save"
action="#{student.updateSkills}" />
</h:form>

-> That doesnt work - the old values are displayed again after invoking the "Save" button.

Thanks
Dirk

P.S: Do I have to use the binding attribute? If yes - can someone point me to a good starting tutorial for that? I cant find any (for me) useful docs for that....



Reply via email to