Reputation: 404
Can I filter multiselect data by searching on a field? This is my code now:
<select id="Multi"
name="multiselectData"
data-role="multiselect"
data-filter="name"
data-text-field="name"
data-value-field="id"
data-bind="value: valueData,
source: sourceData,
events: {
change: onChange
}">
</select>
'data-filter="name"' doesn't work
Upvotes: 0
Views: 379
Reputation: 644
The data-filter
only accepts specific values as mentioned in their documentation.
The supported filter values are startswith, endswith and contains.
Try to set data-filter=contains
. It will automatically filter your data-text-field.
Upvotes: 1