Create org chart with two root managers
Note
For the versions earlier than 4.x.x (including on-premises ones), please follow this instruction. For the versions earlier than 4.3, follow our update instructions.
If your organization has multiple CEOs or you want to display several departments in a view, you can configure multiple root employees. This article explains how to do this using view settings, as well as an alternative approach for earlier versions.
Configure view
Navigate to the Views section and select the view you want to edit. Alternatively, create a new one.
In the Start structure from field, begin typing employee names and select them from the suggested results. You can add up to three employees.
After saving the view, the chart will look like this:
Custom code
If you are using a version earlier than 4.3.2 or need to create multiple root nodes in another scenario, you can use the following workaround.
First, add a placeholder manager at the top of the chart, then hide it with custom JavaScript.
Add the following JavaScript script to the Custom code section to hide the placeholder manager:
api.onBoxRendered((box, itemData) => {
if (itemData["Title"].contains("Manuel Porras")) { // Replace with your own values
$box = $(box.elem);
$box.hide();
$node = $box.closest(".poch-node");
let attempts = 0;
let intervalID = setInterval(() => {
const $lines = $node.find(".poch-node__lines");
if ($lines.length > 0 || attempts == 30) {
$lines.hide();
clearInterval(intervalID);
} else {
attempts++;
}
}, 200);
}
});
The chart now displays multiple root managers:
Conclusion
Now you know how to use Plumsail Org Chart to create org chart with two root managers. If you didn’t install it yet, download it and follow the installation instruction for your version of SharePoint in the documentation. It is quite easy to get started.