In Mendix, you can see if an association is populated with the following Xpath:
This will evaluate to true if an association is populated, so in your case if an employee has a manager assigned. To get a list of Employees who are managers, I think you’ll need to use the reversed keyword, like this:
this will return true if an employee is a manager of one or more employees.
In my experience, its always helpful to test this with test data where you know what the answer is to ensure that you are getting the results you want.
Hope this helps,
I created the following example:
And a page with 2 grids. The first shows all employees, the second shows only those employees who are managers:
The Xpath for the second grid is:
1-* recursion seems logic at first hand, but is not. Answer this: what happens if an employee who is a manager leaves the company? And (temporarily) not replaced. To the employee a manager is always someone playing the role of Department manager, Career-advisor, buddy, HR-councelor and each has different tasks. An extra entity may be something to consider.
Back to your question, “an XPath or even a microflow that asks “Is this employee a manager”: an employer is (also) a manager if the object’s association is not empty.