Microflow validation

1
Hi, In my app it is possible to add an employee with a specific role to a team. However, it is possible to add the same employee with the same role in the same team several times. This shouldn't be possible. Can you please help me get this done? Thanks in advance for the answers.
asked
6 answers
2

Hi Gencehan,

You could include a test in a microflow that runs from the save button on your new employee page that checks whether that employee already exists and if they do show an error message on the form.

How are you determining the uniqueness of the employee, do they have an employee login name or ID, how have you created you employee entity is it a specialization of the account entity?

 

Regards, Steve.

answered
2

 

Sure, here’s an example microflow, I can share the project file as well if you want to look at the detail

answered
1

Here’s a link to the project for this example Link

answered
0

Hi Steve,

Thank you again for your answer.

See my domain model and the page where I bring the three entities together. How can I implement your solution in this?


Medewerker entity means Employee.

 

answered
0

Hi Gencehan,

I think I understand what you are looking for now, have a look at the updated MPK example I just shared, it’s in the same folder location I shared above yesterday, this prevents you adding a team member to the same team with the same SCRUM role.  Let me know if that’s what you were looking for.

answered
0

Hi Steve,

 

Thanks again for your time. Your examples have helped to make it happen.

First I check whether the fields are filled in.

Then I get a list of the attributes. These are then validated to see if the combination exists. If not, it will commit, otherwise the user will get an error.

I use this expression in the retrieve activity to get the attributes i need.

answered