Here I already have a list called users and I am trying to apply a filter. In the apply method, i passed users.AsQueryable(), but its not working as expected. I don't find any overloads from IEnumerable.
[HttpGet]
public JsonResult GetPosts(SieveModel sieveModel)
{
List<User> users = new List<User>();
var result = users.AsQueryable(); // Makes read-only queries faster
result = _sieveProcessor.Apply(sieveModel, result); // Returns `result` after applying the sort/filter/page query in `SieveModel` to it
return Json(result.ToList());
}
Here I already have a list called users and I am trying to apply a filter. In the apply method, i passed users.AsQueryable(), but its not working as expected. I don't find any overloads from IEnumerable.
Is there any option to make it work?