Skip to content

Convert InventoryItem's parent field to an MPTTField #1846

@jeremystretch

Description

@jeremystretch

Issue type

[x] Feature request
[ ] Bug report
[ ] Documentation

Environment

  • Python version: 3.5.2
  • NetBox version: 2.2.8

Description

The parent field of an InventoryItem is used to arrange items hierarchically within a Device. For example:

- FPC 0
    - PIC 0
        - Xvcr 0

Currently, the parent field is a recursive ForeignKey, which does not allow for intelligent hierarchical ordering. We can change this to an MPTTField (like on the Region model) to greatly improve ordering and allow for more efficient queries.

Metadata

Metadata

Assignees

Labels

status: acceptedThis issue has been accepted for implementationtype: housekeepingChanges to the application which do not directly impact the end user

Type

No type

Projects

No projects

Milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions