Reputation: 5421
I'm trying to update an application from Vaadin 7/8 to Vaadin 22.
ListSelect
is gone, so I need a new widget field that satisfies these requirements:
FormLayout
with value bound using Binder
None of the widgets in Vaadin 22 seem to qualify:
Select
and ComboBox
only choose one itemListBox
says ...designed to be used as a lightweight scrollable selection list rather than a form input fieldGrid
does not implement HasValue
so can't be used with Binder
CheckBoxGroup
doesn't look like it will scroll (requirement #3) (I haven't actually tried yet though)What am I missing here?? What is the new equivalent of the old ListSelect
?
Upvotes: 3
Views: 212
Reputation: 4275
If your Grid
is set to multiselect mode, you can use grid.asMultiSelect()
to return a MultiSelect
object that does implement HasValue
and can be used with Binder
. Similarly, in single-select mode, grid.asSingleSelect()
returns a bindable SingleSelect
object.
Upvotes: 2