Hi Christine,
Thanks for using Syncfusion products.
We have analyzed the provided code snippet and suspect that you have passed the grid object directly to the ej.DataManager (“ as ej.DataManager(gridObj).”) instead of passing the grid datasource and hence the data was not filtered correctly.
We can filter the Email field with value “aas@as.com” from grid datasource as follows.
function applyFilter(filterValue) {
var stringValue = filterValue == "All" ? "" : filterValue;
var gridObj = $("#MerchantsGrid").ejGrid("instance");
var filteredActiveData = ej.DataManager(gridObj.model.dataSource).executeLocal(ej.Query().where("Email", ej.FilterOperators.contains, "aas@as.com", false));
}
Now in the above highlighted section, you can see that we have passed the grid datasource to ej.DataManager and now filteredActiveData will contain the filtered value.
If you want to display the filtered value in grid, then we can do as follows.
gridObj.dataSource(filteredActiveData)
|
For more information on performing custom or external filtering in grid, please refer the below link (Refer the External filter section in the below link).
http://help.syncfusion.com/ug/js/default.htm#!documents/filtering1.htm
Please let us know if you have any queries.
Regards,
Madhu Sudhanan. P