Passing the contents of a Data grid 2 to a microflow

0
Hi, I have a Data Grid 2 widget, which has columns using “Custom content” which is a input text widget. The data grid 2 will display stored data which can then be edited. I want to be able to save this data via a microflow. Using a ‘save’ button works, but I can’t seem to pass these data grid 2 contents to a microflow. This data grid 2 essentially holds a list of objects, so I don’t understand why I can’t pass it to a microflow. How can I access the edited data in my data grid 2 in a microflow?  
asked
1 answers
0

Hi Andrew,

 

so far I know it is not possible to pass the DataGrid2-List to a Microflow (at least not without a workaround).

The microflow expects a single Object (in your case a PaymentHistoryTable Object). 

Here are two possible solutions you could consider:

 

  1. On Change Event

In the properties of the input text widget you will find the “Events” tab. You can for example create a “On change” microflow and commit the PaymentHistoryTable Object or you can just select the option “Save changes” (in case that is the only activity you want to do). 

  1. Helper Entity

You can create a Helper-Entity and make an association to your PaymentHistoryTable Entity (many-to-many). On your page you place a DataView with Datasource Microflow and create for example a Microflow called “DS_Helper”. In the DS_Helper Microflow you have an activity which retrieves your PaymentHistoryTableList from the database and the second activity is a Create Object (in this case of the Entity ‘Helper’) and Set the association to the PaymentHistoryTableList – at the end you return the Helper Object.
Now inside of your DataView place the DataGrid2 Widget and select Datasource “Association” and select the PaymentHistoryTable Entity by following the association from the HelperObject of the DataView. Now, when you place a “call a microflow” button inside of your DataView, you will be able to pass your HelperObject, retrieve the PaymentHistoryTableList via association and commit the whole list and do other activities you may want to do.
 

DS_Helper

ACT_Helper_PaymentHistoryTable_Save

 

 

 

answered