I am using my autoComplete as a filter. I want to filter a dataSource using the 'eq' operator when the user selects an item in the autoComplete drop down. I want to filter the dataSource using the 'contains' operator when the user presses the enter key when typing in the autoComplete text box.
I am using both the 'change' and the 'select' events.
From the docs:
'change' - Fired when the value of the widget is changed by the user
'select' - Fired when an item from the suggestion popup is selected by the user
So...
I'm using the 'change' event to filter when the user clicks enter (and therefore use 'contains' operator to filter the ds)
I'm using the 'select' event to filter when the user clicks on a menu item (and therefore use 'eq' operator to filter the ds)
It works well, except when the user selects an item in the drop down, the 'select' event gets fired and then the 'change' event gets fired immediately after. How can I suppress the 'change' event whenever the 'select' event gets fired?
Thanks,
--Ed
I am using both the 'change' and the 'select' events.
From the docs:
'change' - Fired when the value of the widget is changed by the user
'select' - Fired when an item from the suggestion popup is selected by the user
So...
I'm using the 'change' event to filter when the user clicks enter (and therefore use 'contains' operator to filter the ds)
I'm using the 'select' event to filter when the user clicks on a menu item (and therefore use 'eq' operator to filter the ds)
It works well, except when the user selects an item in the drop down, the 'select' event gets fired and then the 'change' event gets fired immediately after. How can I suppress the 'change' event whenever the 'select' event gets fired?
Thanks,
--Ed