Problem:
I have a grid with lazy loading and therefor my data is not in memory.
To show the check box to select/deselct all i used this Question. My code looks like this:
// set selection mode
grid.setSelectionMode(SelectionMode.MULTI);
// make select all check box visible
GridSelectionModel<ProofTemplate> selectionModel = grid.getSelectionModel();
((GridMultiSelectionModel<ProofTemplate>) selectionModel)
.setSelectAllCheckboxVisibility(SelectAllCheckboxVisibility.VISIBLE);
The Problem is, that the check box does not work in the UI as you can see:
If i log the selected items with the following code the check box works as expected
grid.addSelectionListener(l -> {
log.info("selected: " + l.getAllSelectedItems().size());
});
Question:
What can i do that the check box also works in the UI?
Aucun commentaire:
Enregistrer un commentaire