Here our requirement is two fields(displayField & valueField) are displayed in combo list, if we filter the one field either displayField or valueField, the filter value is display in combo.
an attribute for inner interaction instead of default id
from the combo configuration?
While the 1st and 2nd are rather easy to implement with a simple templates ( https://webix.com/snippet/a5f3fef2 ), the 3rd option is not recommended for implementation, as all logic of Webix data components (including the list inside the combo) is based on the unique ID of an item.
. If we search the df value means the df value will be displayed in input, otherwise if we search the vf value means the vf value will be displayed in input, is there any possibility??
Filtering function will be called for every item and in fact, without some strict condition for the value typed by user there’s no way to distinguish whether he/she searches for displayField or valueField.
If you have such condition, you can embed a custom flag into the combo view or add it to a combo-based component. Here’s an example of such logic:
now we want to search via synonyms,
if we search df value means vf value should be hide,if we search vf value means df value should be hide,
plz follow the below snippet
The template in body can rely on the same type of logic except for one point: templates of data components (list, datatable, etc) have different scope and this here refers to the entire Window object, not to the component.
So in any case, you need to know the ID of the master combo or at least ID of a list on which you apply the template.