mirror of
https://github.com/netbox-community/netbox.git
synced 2026-01-11 21:10:29 +01:00
Add "Inventory Item Type" #2729
Closed
opened 2025-12-29 18:21:28 +01:00 by adam
·
21 comments
No Branch/Tag Specified
main
update-changelog-comments-docs
feature-removal-issue-type
20911-dropdown
20239-plugin-menu-classes-mutable-state
21097-graphql-id-lookups
feature
fix_module_substitution
20923-dcim-templates
20044-elevation-stuck-lightmode
feature-ip-prefix-link
v4.5-beta1-release
20068-import-moduletype-attrs
20766-fix-german-translation-code-literals
20378-del-script
7604-filter-modifiers-v3
circuit-swap
12318-case-insensitive-uniqueness
20637-improve-device-q-filter
20660-script-load
19724-graphql
20614-update-ruff
14884-script
02496-max-page
19720-macaddress-interface-generic-relation
19408-circuit-terminations-export-templates
20203-openapi-check
fix-19669-api-image-download
7604-filter-modifiers
19275-fixes-interface-bulk-edit
fix-17794-get_field_value_return_list
11507-show-aggregate-and-rir-on-api
9583-add_column_specific_search_field_to_tables
v4.5.0
v4.4.10
v4.4.9
v4.5.0-beta1
v4.4.8
v4.4.7
v4.4.6
v4.4.5
v4.4.4
v4.4.3
v4.4.2
v4.4.1
v4.4.0
v4.3.7
v4.4.0-beta1
v4.3.6
v4.3.5
v4.3.4
v4.3.3
v4.3.2
v4.3.1
v4.3.0
v4.2.9
v4.3.0-beta2
v4.2.8
v4.3.0-beta1
v4.2.7
v4.2.6
v4.2.5
v4.2.4
v4.2.3
v4.2.2
v4.2.1
v4.2.0
v4.1.11
v4.1.10
v4.1.9
v4.1.8
v4.2-beta1
v4.1.7
v4.1.6
v4.1.5
v4.1.4
v4.1.3
v4.1.2
v4.1.1
v4.1.0
v4.0.11
v4.0.10
v4.0.9
v4.1-beta1
v4.0.8
v4.0.7
v4.0.6
v4.0.5
v4.0.3
v4.0.2
v4.0.1
v4.0.0
v3.7.8
v3.7.7
v4.0-beta2
v3.7.6
v3.7.5
v4.0-beta1
v3.7.4
v3.7.3
v3.7.2
v3.7.1
v3.7.0
v3.6.9
v3.6.8
v3.6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3
1.0.0
Labels
Clear labels
beta
breaking change
complexity: high
complexity: low
complexity: medium
needs milestone
netbox
pending closure
plugin candidate
pull-request
severity: high
severity: low
severity: medium
status: accepted
status: backlog
status: blocked
status: duplicate
status: needs owner
status: needs triage
status: revisions needed
status: under review
topic: GraphQL
topic: Internationalization
topic: OpenAPI
topic: UI/UX
topic: cabling
topic: event rules
topic: htmx navigation
topic: industrialization
topic: migrations
topic: plugins
topic: scripts
topic: templating
topic: testing
type: bug
type: deprecation
type: documentation
type: feature
type: housekeeping
type: translation
Mirrored from GitHub Pull Request
Milestone
No items
No Milestone
Projects
Clear projects
No project
Notifications
Due Date
No due date set.
Dependencies
No dependencies set.
Reference: starred/netbox#2729
Reference in New Issue
Block a user
Blocking a user prevents them from interacting with repositories, such as opening or commenting on pull requests or issues. Learn more about blocking a user.
Delete Branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Originally created by @candlerb on GitHub (Jul 6, 2019).
(Factoring this idea out of #3087)
Environment
Proposed Functionality
Add "Inventory Item Type". The relationship would then be Inventory Item
->Inventory Item Type->Manufacturer. This is analogous to the relationship Device->Device Type->Manufacturer.I propose making this as similar to Device Type as possible. e.g.
I also propose that the existing "Description" field in Inventory Item would be renamed to "Comments", to be consistent with Device.
Use Case
Database Changes
(manufacturer, model name)Note: there will need to be a data migration with automatic creation of inventory item types to support this change. One way to do this would be to automatically create a new inventory item type for each unique combination of "Manufacturer" + "Part ID", using the Part ID for model name as well. If Part ID is null it would have to become model name "Unknown".
(I think it's unlikely that the "Description" field on inventory item has been applied consistently enough to be used as Model Name, but it can be left as "Comments")
Allowing Custom Fields on inventory item types, as they are for device types, would be useful for several different purposes.
External Dependencies
None
Further thoughts
It has been suggested separately that inventory item types should be linked to device types, but I think that's a separate issue and is more complex - it would necessarily be a many-to-many relationship.
It could also be useful to be able to classify inventory item types, e.g. "Hard drive", "RAM", "CPU" etc, making them easier to select. Applying roles to inventory item types, rather than individual inventory items themselves (#3087) might be a way to achieve this. But it could also be done just with a custom field.
@darcynz commented on GitHub (Oct 10, 2019):
2nd this. Although I would leave the description fields as this relates to an field quite often used specifically by the inventory Item. -> Eg Cisco Line cards.
Custom fields would be good solution and this has been discussed -> #1120.
@jeremystretch commented on GitHub (Oct 15, 2019):
This seems like it's pushing NetBox too far into asset management territory. Hardware inventory modeling was added with the primary function of allowing the user to locate hardware by serial number. Components were originally intended to be discovered automatically (although that functionality has since been removed).
@thannaske commented on GitHub (Nov 12, 2019):
Netbox is designed to be a DCIM (yes, also IPAM). In order to properly manage your DC sites you need to track how many and which spare parts you have on-site in order to call remote hands services or to restock your spares. I'm currently looking for a way to achieve this with Netbox and a functionality like this would help.
@darwin67 commented on GitHub (Dec 17, 2019):
That's an interesting statement. If Netbox is supposed to be a DCIM tool, shouldn't asset management be included in the scope as well?
@jeremystretch commented on GitHub (Dec 17, 2019):
@darwin67 For better or worse, this is where we've drawn the line on scope, a necessary delineation to ensure NetBox remains maintainable. It this does not meet your needs, NetBox may not be the tool for you.
@darwin67 commented on GitHub (Dec 17, 2019):
Fair enough. So if I want asset management and other things that are not considered the core functionalities, I should either fork the repo and extend it myself or wait for #3351 and build a plugin for it then?
@lndmnn commented on GitHub (Jan 16, 2020):
As @thannaske mentioned.. It would be great to give it the ability to create for example Hard Drives and assign them to a Server. If the Hard Drive will be replaced, it would be great to mark the fault drive as broken, so that we can track all broken and active devices in the future.
@ibivibiv commented on GitHub (Feb 11, 2020):
First off, hello to everyone... I have been living in the shadows here for quite some time. I would think that in the day to day business of keeping devices alive that you would want to track drift of the assets as they get repaired. Also they can change shape a bit over time. Allowing inventory items to be typed and have lifecycle equal to that of devices is quite sensible in my mind. I do see that the primary "delineation" seems to be around resources and maintenance to keep this application reasonable. If that were to be alleviated and I could provide assistance (more than just myself) to bring such features to the table, would that help relax concerns about bringing inventory items features forward? And when I say resources, I am not talking about a drive by dumping of code. I am talking about active members working the project and keeping that code up to date. I'm looking to see if this is just a philosophical concern or more of a scope and resources concern? We really like this application and want to improve it and maintain its place going forward. If we need to "prove ourselves" we can always do a period of bug fixes and enhancements and then revisit this current set of features to get a comfort level with each other as well. I certainly wouldn't expect anything less given this is my first open contact with all of you. :). Let me know what the thinking is here and lets see where we can take this!
@thannaske commented on GitHub (Feb 11, 2020):
As far as I understood the main issue with this proposal was that it would be out of scope of netbox. Netbox (aside from the IPAM-functionality) describes itself as DCIM (Datacenter Infrastructure Management) tool. And the reality is that almost everyone that runs some racks in a DC has a storage unit somewhere where drives, RAM or some 3.5"-to-2.5" caddy are stored.
I don't see how this is out of scope. We are fastidiously documenting what is on which height unit and then there is a 3 HE drawer and I just can't keep track of its contents. For me it seems like a clear lack of functionality. I don't have the expectation to track a whole lifecycle for inventory items or server parts, for our personal use case it would be sufficient if we just would know what is current on spare and what not so people don't have to take everything they could possibly need with them, but can look up what's on stock instead. For all the level 1 technicans out there this would be a great benefit and improvement and is clearly in scope of a DCIM imho.
@ibivibiv commented on GitHub (Feb 11, 2020):
I would think though if you have them live outside the context of the server they reside in then you would want to know their state? As in lifecycle of "in inventory, in use, broken, etc."? Maybe "lifecycle" was a bad choice of words. Status probably is a better one. I would think minimally; typed, statuses, and locality are important at the minimum.
@ibivibiv commented on GitHub (Feb 14, 2020):
I am thinking these are some decent wire frames of what is involved. I am not sure we'd want to get into the business of "locations" just yet. Site is there, but it does beg the question that if you wanted to say place an inventory item in a holding location that site might not suffice there. Anyway just a quick mockup I did. Apologies for the color oddities (its the tool I'm using)
@ibivibiv commented on GitHub (Feb 16, 2020):
I also started working up a data domain model of what this might end up being as well.
@ryanmerolle commented on GitHub (Mar 11, 2020):
v2.8 is coming soon. I would totally be interested in a asset management plugin for spares. Right now I track them via markdown in the comments table of a site.
@ibivibiv commented on GitHub (Apr 10, 2020):
FYI, both the typing and the role have been implemented in a fork here:
80943c7ab9If we can get an actual issue up for this and get it accepted we can get this ball rolling? If we are deadlocked then maybe we build out something else in a companion app? I think it would be better to have this functionality built in rather than having to go around it just to track what a component inside a server is and its role?
@skredder commented on GitHub (Jun 15, 2020):
@ibivibiv Would also be very interested in such a functionality here. Glad to help along and dedicate time and resources for it.
As I don't expect anything like this would be accepted in the main Netbox branch anytime soon, a separate plugin would be the most suitable.
@igloo777 commented on GitHub (Nov 20, 2020):
Hi all)
I created a similar request (for tracking components) in SnipeIT 3 years ago. And this is still not implemented there. I am still getting notifications of SnipeIT users voting to track components. Seems like it highly demanded feature.
@jeremystretch commented on GitHub (Dec 21, 2020):
This seems like it would be the biggest impediment to implementing this proposal. Both the
manufacturerandpart_idfields are optional: How would we automatically migrate to the new model in scenarios where one or both fields may be undefined?@jeremystretch commented on GitHub (Dec 22, 2020):
This issue should be considered in conjunction with #824, as there seems to be potential for overlap.
@candlerb commented on GitHub (Dec 22, 2020):
@stale[bot] commented on GitHub (Feb 6, 2021):
This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. NetBox is governed by a small group of core maintainers which means not all opened issues may receive direct feedback. Please see our contributing guide.
@stale[bot] commented on GitHub (Mar 5, 2021):
This issue has been automatically closed due to lack of activity. In an effort to reduce noise, please do not comment any further. Note that the core maintainers may elect to reopen this issue at a later date if deemed necessary.