Filtration

Note

For the versions earlier than 4.x.x (including on-premises ones), please follow this instruction.

Start structure from employee

You can start the hierarchy from a specific employee. Just start typing the employee name. Org Chart will suggest some matching names.

You can leave the starting employee field empty. In this case:

  • If you use User profiles, the starting employee will be found based on current user relations. Org Chart will find the current user. Then it will traverse up by manager relation until it finds an employee without a manager. This person will be a starting employee.

  • If you use a SharePoint list, the first employee without a manager will be a starting employee.

Start the structure with

Filter employees

Check this article for example on filtration employees by department. You can use the filtration rule to exclude people from the chart or show just specific departments or employees. You may filter by department, name, or by any other field from your data source.

Note

The filtration rules are case sensitive.

Simple editor

This editor contains a set of conditions that are resolved either to true or false. Click the Add condition button to create a new one. The org chart box will be displayed if it meets All or Any of the conditions. Each one consists of:

  • a drop-down list for selecting a data source field,

  • a drop-down list with comparison operators,

  • a text field for a custom value.

Note

There is a specific operator Matches that allows to check whether the current value matches with a defined regular expression.

Simple condition editor

Advanced editor

This editor contains a JavaScript function that evaluates data for the org chart box and returns a boolean value. If true, then the box with such data will be displayed.

You can use itemData input parameter to access data for the current box and verify it. Use internal names of properties to access their values like this: itemData["Department"]. Find all the available properties in the Field names list - click any to copy the internal name to the clipboard and use it in the code below.

List of available fields

Use typical JavaScript conditions, comparison operators, and functions like indexOf to verify data. For example, you may need to include in the org chart only employees from the specific department. In this case, the function to display employees from the Marketing department looks like this:

function(itemData){

  return itemData["Department"] == "Marketing Department";

}
Filtration function

And with this filter, you can exclude all employees whose name contains Smith in user profiles:

return !itemData["PreferredName"].contains("Smith");

Note

Go to the next step of the configuration wizard Layout & Skin.