Anyone have tried to test AutoQuery in the NorthWind example?
I have added the ServiceStack.Server dependency to the solution, then:
Plugins.Add(new AutoQueryFeature { MaxLimit = 100 });
container.Register<IDbConnectionFactory>(
new OrmLiteConnectionFactory("~/Northwind.sqlite".MapHostAbsolutePath(), SqliteDialect.Provider));
and then in the Orders:
[Route("/orders")]
[Route("/orders/page/{Page}")]
[Route("/customers/{CustomerId}/orders")]
public class Orders : QueryBase<Order>
{
public int? Page { get; set; }
public string CustomerId { get; set; }
}
but if I try, for example, to query: /orders?OrderByDesc=Id I can’t have the Orders list in descending order…
Where I’m wrong?