how manager can view only his particular employee data

1
Hello everyone, An employee is assigned to multiple list of managers and one manager can have multiple employees. So all the managers who are assigned to that employee can view that employee data. For multiselect of managers we can use input reference set selector. But my question is how to make a logic that whenever the managers login he should be able to see only his employee data. (Note: this can be achieved if the association between employee entity and manager entity is one to many.).. but how it is achieved if the association between employee entity and manager entity is many to many   Thanks in advance, 
asked
2 answers
2

You would need to go to the domain model, double click on your employee entity and add a security rule for the manager which has an xpath to the user.

Something like:

[Module.Employee_Manager/Module.Manager/Module.Manager_Account = '[%CurrentUser%]']

answered
1

You could add xpath constraints to your domain model so that a manager is only allowed to see employees associated with him.

If that is not possible because of other program logic, you can add such a constraint to your data grid/view/…

The xpath does not care if its 1-1, 1-* or *-*

answered