Trigger Microflow on single selection in datagrid.

1
I either need a grid with single click + single selection + microflow (setting the selection to an object) or a listener that automatically calls a microflow whenever the selection changes. The problem with a single click is that it requires no selection, but I need single selection for the New/Edit/Delete buttons.
asked
3 answers
2

How about the datagrid extension widget? You can use it to add inline buttons in your grid and get close to what you're looking for. In fact, that may be more intuitive depending on your use case.

The other option would be to create a custom widget that fires a microflow on update, and put that into a listening data view. The actual code required to make that happen would be pretty simple, though there is a learning curve if you've never built a widget before. I'd recommend referencing code from other widgets that perform similar functions (i.e. call a microflow).

answered
1

You could also achieve this by using jQuery. When another row is selected, you could use jQuery to simulate a click on the button, which will trigger the microflow.

If you have any questions, please let me know.

answered
0

I wanted to boost this thread by presenting my own solution to the problem.

  • Add a dataview as listen-to-widget listening to the datagrid
  • Set the dataview class property to “hidden”
  • Add a Microflow timer in the dataview with attached microflow that handles your logic
  • Call the microflow every 1000 ms (or more often)
  • Make sure to check for an empty parameter object in your microflow and to refresh your changed object(s).


Happy modeling!

answered