I have a customer with multiple orders that could have one or more orderlines. I publish a Webservice in which the customer is returned based on his customer number. It should also return all the orders with status paid and all the orderlines for that order with status approved. How do I do that? I can only return an object or list with customer(s) and then select the associated orders and orderlines; however, I cannot constrain that selection (while I need to do that).
Currently this is not possible. I suggest filing a feature request in the support portal.
As a workaround, you could create separate associations from Customer to Order and from Order to OrderLine containing only those items that you want to put in the response. You could fill these associations before returning the Customer object from the published web service microflow.
Benny van Reeven
Use a find by Microflow? You can use the toplevel customer as a parameter and then filter the orders in the flow.