Viritin MultiSelectTable no selection

Hi,

Is it possible with MultiSelectTable to
not
select rows?
If the table is initially created, there are no selections.
But once I’ve selected a row, I can only select another row,
and not deselect the current row (without selecting a new row).

I have a 0:N relations that I edit with a MultiSelectTable,
therefore selecting not any row is also a valid selection.

Thanks.

The Table’s multiselect mode works like that. Additional rows are selected with CTRL/CMD(mac). There is also the “legacy multiselect mode” setMultiSelectMode(MultiSelectMode.SIMPLE).

If you want to ensure there is a selection, you should verify that with a validator. Then you can easily maintain the state of Save button so that invalid stuff don’t get into your backend. With AbstractForm (Viritin helper class) this is handled automatically for you.

cheers,
matti

Thanks,

I use now setMultiSelectMode(MultiSelectMode.SIMPLE) for the table of the MultiSelectTable and then I can deselect every selection I made.

– JG