I would like to show the orders of the selected customer in the grid via an action button. For this, I have linked a microflow to this action button. In this microflow the input parameters CustomerList and Customer are automatically added. The CustomerList object contains the selected customer in the grid, but the Customer object still contains the first customer. This means that, when I am trying to retrieve orders and/or pass the Customer object to the page, incorrect data is shown. What is the best practice here? Should I remove the Customer object as input parameter and somehow retrieve it based on the customer list, or is there a way to equal the Customer object to the selected customer (CustomerList)?
Arjan van den Top
I may not completely understand what you are trying to accomplish, but if you have a grid containing Customer objects, you can display the Orders associated with a selected Customer without using a microflow. To do this:
Ensure that your grid is configured for single selection
Create a page containing a dataview of the Customer entity
Nested in this dataview, create a DataGrid (or ListView or TemplateGrid) that displays Orders via an association between Customer and Orders. You can use Database, XPath or Association as the datasource of this nested object.
Now add a button to the control bar of the grid on the original page. Configure this button to open a page, and select the page you just created.
When you open this page, it will show a list of Orders associated with the selected customer.
One note: you can also do this by creating a Dataview on the original page whose datasource is listen to grid. Chose the customer datagrid as the source. Inside of this dataview, create a grid that displays Orders associated with the customer.
Hope that helps,
In the meantime I found some information in a blog post related to this subject. See below microflow for a working solution to my problem. In case there are other or better solutions, I would be glad to hear about it.