gws.plugin.model_widget.select¶
Select widget.
Drop-down list with a fixed set of items, optionally with a search field.
Each item has a value, which is stored in the field, and a text to display,
which defaults to the value. The extraText and level options of an
item are not passed to the client.
Example:
fields+ {
name "kind"
type "text"
widget {
type "select"
withSearch true
items [
{ value "a" text "Type A" }
{ value "b" text "Type B" }
]
}
}
Source code: gws.plugin.model_widget.select
Package Contents¶
- class gws.plugin.model_widget.select.Config¶
Bases:
gws.base.model.widget.ConfigDrop-down list with a fixed set of values.
- items: list[ListItemConfig]¶
Options to choose from.
- class gws.plugin.model_widget.select.ListItem(*args, **kwargs)¶
Bases:
gws.DataItem in the select widget.
- class gws.plugin.model_widget.select.ListItemConfig(*args, **kwargs)¶
Bases:
gws.ConfigOption of a select widget.
- class gws.plugin.model_widget.select.Object¶
Bases:
gws.base.model.widget.ObjectSelect widget object.
- props(user)¶