I'm passing a hashmap which consists out of an object + a boolean into my view and I want to display the value of the boolean of each object and currently have the following code:
<ui:repeat var="item" value="#{userTypeController.permissionItems}">
<h:outputText value="#{item}" />
<h:selectBooleanCheckbox value="#{userTypeController.checkMap[item]}"/>
</ui:repeat>
And the Hashmap method:
public Map<Permission, Boolean> getCheckMap() {
checkMap = null;
for (Permission p : getPermissionItems()) {
if (getPermissionItemsUserType().contains(p))
checkMap.put(p, Boolean.TRUE);
else
checkMap.put(p, Boolean.FALSE);
System.out.println(checkMap.get(p).toString());
}
return checkMap;
}
This should work and during the system.out.println I see a true output...
However, the checkboxes itself are never checked... Any idea on what I'm doing wrong here?