Display full rack group hierarchy when viewing a rack/device #4103

Closed
opened 2025-12-29 18:33:08 +01:00 by adam · 2 comments
Owner

Originally created by @ypid on GitHub (Sep 15, 2020).

Originally assigned to: @jeremystretch on GitHub.

Environment

  • Python version: 3.7.3
  • NetBox version: 2.9.3

Proposed Functionality

Display full rack group hierarchy in /dcim/racks, /dcim/racks/{id} and /dcim/devices/{id}.

Use Case

As https://netbox.readthedocs.io/en/stable/core-functionality/sites-and-racks/ notes, rack groups can be hierarchical to model for example buildings -> floors -> rooms -> rack rows. Example values:

Factory building 1 -> Level 1 -> R101 -> Row 1

Currently, /dcim/racks/ only shows "Row 1" under "Group". At least in /dcim/racks/{id}, there is enough space to show the full hierarchy. Under /dcim/racks/ it could be a configurable column.

Similar under /dcim/devices/{id} except that here the last rack group hierarchy level is already shown. For the example: Row 1 -> Rack 1. Here it would be more helpful to write the full hierarchy.

What makes this currently even more tricky to use without redundancy is that clicking on the hyperlinks does not show you the hierarchy either.

Regions can also be hierarchical but I would argue that regions have a different semantic with the common use of geographical regions, there is basically a 1:n mapping (example Germany is in Europe) whereas rack groups can be n:m (with multiple "Row 1" and multiple "Level 1"). I would not necessarily apply the same logic to regions even though it could (/dcim/sites/{id} has also space in the table usually).

Database Changes

No.

External Dependencies

No.

Originally created by @ypid on GitHub (Sep 15, 2020). Originally assigned to: @jeremystretch on GitHub. <!-- NOTE: IF YOUR ISSUE DOES NOT FOLLOW THIS TEMPLATE, IT WILL BE CLOSED. This form is only for proposing specific new features or enhancements. If you have a general idea or question, please post to our mailing list instead of opening an issue: https://groups.google.com/forum/#!forum/netbox-discuss NOTE: Due to an excessive backlog of feature requests, we are not currently accepting any proposals which significantly extend NetBox's feature scope. Please describe the environment in which you are running NetBox. Be sure that you are running an unmodified instance of the latest stable release before submitting a bug report. --> ### Environment * Python version: 3.7.3 * NetBox version: 2.9.3 <!-- Describe in detail the new functionality you are proposing. Include any specific changes to work flows, data models, or the user interface. --> ### Proposed Functionality Display full rack group hierarchy in `/dcim/racks`, `/dcim/racks/{id}` and `/dcim/devices/{id}`. <!-- Convey an example use case for your proposed feature. Write from the perspective of a NetBox user who would benefit from the proposed functionality and describe how. ---> ### Use Case As https://netbox.readthedocs.io/en/stable/core-functionality/sites-and-racks/ notes, rack groups can be hierarchical to model for example `buildings -> floors -> rooms -> rack rows`. Example values: Factory building 1 -> Level 1 -> R101 -> Row 1 Currently, `/dcim/racks/` only shows "Row 1" under "Group". At least in `/dcim/racks/{id}`, there is enough space to show the full hierarchy. Under `/dcim/racks/` it could be a configurable column. Similar under `/dcim/devices/{id}` except that here the last rack group hierarchy level is already shown. For the example: `Row 1 -> Rack 1`. Here it would be more helpful to write the full hierarchy. What makes this currently even more tricky to use without redundancy is that clicking on the hyperlinks does not show you the hierarchy either. Regions can also be hierarchical but I would argue that regions have a different semantic with the common use of geographical regions, there is basically a 1:n mapping (example Germany is in Europe) whereas rack groups can be n:m (with multiple "Row 1" and multiple "Level 1"). I would not necessarily apply the same logic to regions even though it could (`/dcim/sites/{id}` has also space in the table usually). <!-- Note any changes to the database schema necessary to support the new feature. For example, does the proposal require adding a new model or field? (Not all new features require database changes.) ---> ### Database Changes No. <!-- List any new dependencies on external libraries or services that this new feature would introduce. For example, does the proposal require the installation of a new Python package? (Not all new features introduce new dependencies.) --> ### External Dependencies No.
adam added the status: acceptedtype: feature labels 2025-12-29 18:33:08 +01:00
adam closed this issue 2025-12-29 18:33:08 +01:00
Author
Owner

@jeremystretch commented on GitHub (Sep 16, 2020):

We can extend the breadcrumbs (the lineage displayed at the top of the page) to include all parent rack groups, but the tables will need to stay as they are. You can view the assigned rack group to see it's full hierarchy, or navigate by the rack groups list.

@jeremystretch commented on GitHub (Sep 16, 2020): We can extend the breadcrumbs (the lineage displayed at the top of the page) to include all parent rack groups, but the tables will need to stay as they are. You can view the assigned rack group to see it's full hierarchy, or navigate by the rack groups list.
Author
Owner

@candlerb commented on GitHub (Sep 24, 2020):

Question: when viewing a device, is the rack supposed to be included in the breadcrumbs now?

With Netbox 2.9.4, when I go to /dcim/devices/<NN>/ I see breadcrumbs as

Devices / <sitename> / <devicename>

There is no rack, even though this is a racked device (note: I'm using racks without rackgroups)

If this is expected, then I'd suggest changing the issue title from "...when viewing a rack/device" to "...when viewing a rack"

@candlerb commented on GitHub (Sep 24, 2020): Question: when viewing a device, is the rack supposed to be included in the breadcrumbs now? With Netbox 2.9.4, when I go to `/dcim/devices/<NN>/` I see breadcrumbs as ``` Devices / <sitename> / <devicename> ``` There is no rack, even though this is a racked device (note: I'm using racks without rackgroups) If this is expected, then I'd suggest changing the issue title from "...when viewing a rack/device" to "...when viewing a rack"
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: starred/netbox#4103