itemclass and onhand do not exist anywhere in the code. We parse the query parameters and use them to build our special sql queries.
Using your format:
[HttpGet, route('list')]
Function GetSimpleList([FromQuery] Filter:String):TObjectlist<TLineItemList>;
Does not work as needed. First, it requires the filter param, and then it creates something like: http://xxx.xxx.xxx.xxx\list?filter=itemclass%19stocked which is incorrect for our needs. The filter= should not be there. It should be Itemclass=stocked
Maybe I am doing it wrong or there are different options I am not aware of.
Maybe I need to use the System.Net.URLClient unit and parse the URL from TXDataOperationContext.Current.Request.RawUri. This way I have no fixed limitations.
I was just showing you the things that makes XData stand out. But if it doesn't fit your needs, that's fine, you go to a lower level.
This "custom filter" mechanism is even higher level if you mix XData and Aurelius, as explained here: TMS Software | Blog
But as I said, you can go low level if you need to.
And by the way, you can have optional query parameters by using Nullable<T> types, or default parameter values, or you can even use a class DTO as a query parameter so that the mapped fields of such class will be the query parameters.