netbox-community / netbox

The premier source of truth powering network automation. Open source under Apache 2. Try NetBox Cloud free: https://netboxlabs.com/free-netbox-cloud/
http://netboxlabs.com/oss/netbox/
Apache License 2.0
16.1k stars 2.58k forks source link

IPAM Site Prefixes render children indent when the parent is not assigned. #15142

Closed jchambers2012 closed 8 months ago

jchambers2012 commented 8 months ago

Deployment Type

Self-hosted

NetBox Version

3.7.2 and 3.6.5

Python Version

3.11

Steps to Reproduce

Hide Depth Indicators work as expected but with the indicator on can cause some confusion.

  1. Navigate to IPAM -> Prefixes
  2. Add new prefix with the following settings. PREFEX: 10.112.157.0/24 DESCRIPTION: BROKEN PARENTS Site: DM-Akron
  3. Create
  4. Navigate to Organization -> Site -> DM-Akron -> Click Prefixes
  5. 10.112.157.0/24 looks like it a child of 10.112.128.0/22 image

This can be more "confusing" when adding more 45.x.x.x/x networks: For example add the following Prefixes:

Global Prefixes View: Navigate to IPAM -> Prefixes image

Site Prefixes View: Navigate to Organization -> Site -> DM-Akron -> Click Prefixes image

Expected Behavior

Since the parent is not "linked" to this Site the three dots should not be rendered or some other GUI object should be rendered pointing to it true parent?

One thought when in this filter view:

Observed Behavior

All prefix are indented based on where they live on the global prefix list: image

jeremystretch commented 8 months ago

Goto https://demo.netbox.dev/ipam/prefixes/

Please revise your report above to remove all references to the demo instance.

jchambers2012 commented 8 months ago

@jeremystretch - removed - let me know if that will work as having existing data from the demo site was used in the screenshot examples above.

jeremystretch commented 8 months ago

This is working as expected; the indentation annotates each prefix's depth in the hierarchy. If you'd prefer not to see this, you can replace the default "prefix" column in the table configuration with "prefix (flat)", which does not annotate depth.