When using "GetAll" method, we can set a selector to project the stored data into an object with different shape like below :
public List<MyProjectedObject> GetPropjectedObjects(IQueryOptions<MyObject> options)
{
return
this.GetAll(
it =>
new MyProjectedObject
{
Id = it.Id.ToString(),
Name = it.Name,
Code = it.Code,
}, options)
.ToList();
}
Is it possible to filter and sort the result by the projected object rather than the stored one ? It seems that SharpRepository only sort/filter on the store objects and that is quite limitating in some situations ..
Thanks !
Riana