hr_department_chart
The department's place in the org: parents above, children below, each clickable to open the employees inside it.
August 27, 2026Updated September 7, 20264 min read
| Technical name | hr_department_chart |
|---|---|
| Views | form (view widget, <widget> element) |
| Module | hr, the Employees app |
| Used in core | The department form in hr |
| Versions | Odoo 20.0, Odoo 19.0, Odoo 18.0, Odoo 17.0 |
| No-code setup | No. It is set in view XML and depends on module-specific data |
| Alternatives | many2one_avatar_employee, hr_leave_stats, button_new_contract |
What the department chart does
What this means for your team
Supported options in Odoo 19
| Option | Type | What it does |
|---|---|---|
get_department_hierarchy | server call | Returns the whole structure around the department in one payload. |
action_employee_from_department | server call per click | Returns an action showing that department's employees, which is then opened. |
the props change hook | refetch trigger | Refetches the hierarchy when the record changes without the component being recreated. |
Both the shape and the click are server decisions. The hierarchy comes from one call, and each click asks for an action rather than constructing one, which keeps access rules and context in the server's hands.
Working examples
One call for the shape, one per click
Version compatibility
| Version | Status | Notes |
|---|---|---|
| Odoo 20.0 | Partial / changed | Not released. Reworked around newer conventions. |
| Odoo 19.0 | Verified | Verified against the shipped source. |
| Odoo 18.0 | Verified | Same hierarchy call and click action. |
| Odoo 17.0 | Verified | Same approach with older component conventions. |
| Odoo 16.0 | Not available | Widget does not exist. |
Upgrade note. Present since Odoo 17. The single hierarchy call and the action-per-click pattern have been stable across those versions.
What is changing in Odoo 20
Common problems and fixes
| Symptom | Cause and fix |
|---|---|
| The chart is empty | The department has no parent and no children. Expected for a flat structure. |
| The chart shows the previous department | It should not; a props change triggers a refetch. Reload the form if a customization interfered. |
| Clicking opens the wrong records | The action is requested from the model the widget sits on. Use it on the department form, which is what it expects. |
| Some departments are missing | Record rules filtered them out of the server's answer. Expected. Access rules apply to the hierarchy call. |
| Employee counts look wrong | They come from the server payload. Check the employees are assigned to the department. |
| The widget is missing | The employees module is not installed in that database. Install Employees. |
Department chart vs the alternatives
| Widget | Best for | Key difference |
|---|---|---|
hr_department_chart | Seeing a department's place in the organization from its own form | One server call for the whole shape, and an action requested per click |
| many2one_avatar_employee | Showing a department manager | A person on a record rather than the structure |
| hr_leave_stats | Leave context on a request | Availability rather than structure |
| button_new_contract | Starting a contract | An action rather than a chart |
Frequently asked questions
Where does the chart data come from?+
What happens when I click a level?+
Why request an action instead of building one?+
Does it update when I move between departments?+
Which versions have it?+
An org structure your HR system agrees with
Departments, managers and cost centers often diverge quietly, and payroll finds out first. We implement Odoo HR so the structure holds up, on versions 16 through 19.
Book a free consultation