Popup form opens multiple times

1
In my current project a microflow calls a popup form to achieve the following: From the List of Employees, one can be selected, the Microflow button clicked, and a popup opens to allow e.g. the Promotion of that Employee. For that the employee and his old Job title need to be passed to the foem, and I used a nested data view to show the Promotion Form, which sets the date and the new job title. Unfortunately I don't get any error messages when I test-run the project, but the popup opens over and over again spamming the entire screen. EDIT: Used the debugger on every event of the microflow: HR_Training.Promotion - Start - Show 'Promotion' (196 microseconds) - 'Create Promotion' returns 'NewPromotion' (2 milliseconds) - End
asked
2 answers
2

I recommend debugging the microflow and seeing if that open form activity is called multiple times (perhaps the microflow is called in a loop?)

Based on comments in your original question:

That situation would result in an infinite loop indeed, the data source microflow definitely shouldn't open a new form again. Also I don't think you should actually make a new object in the data source microflow as this would create new objects every time. The idea of the data source microflow is that you retrieve the related object for your nested dataview in some way.

So in your form opening microflow you could create (and commit) the promotion object and then in your form you can use a data source microflow to retrieve that object, or alternatively use a path to fill the nested dataview (but this might not be possible depending on how you set up your domain model, this can only be done if an Employee can have only one Promotion)

Also see the dataview documentation and check the data source properties.

answered
0

I tried the debugger, it opened with every popup in a new window, as if there was an infinite loop. However there is not a single loop in the entire project.

answered