Plugin that shows NetBox devices and modules in tables.
Project description
Inventory Viewer
Inventory Viewer is a plugin for NetBox that displays modules (NetBox dcim.Module objects) in tables, grouped by their module types. This plugin is especially helpful if you need a quick overview of installed modules and their properties (like serial numbers, asset tags, location, cable connections, notes, and custom fields).
Features
- Grouped Module Tables: Displays modules organized by module type on a dedicated page.
- Custom Fields Integration: Shows data from custom fields (e.g., “rok_zavedeni” or “merici_bod”) if present.
- Cable Connections: Prints out cable termination endpoints for each module, indicating how they’re connected.
- Site & Location Overviews: For each module, provides an at-a-glance view of where it resides (site, location, device).
- Easy Navigation: Integrated into NetBox’s main menu (under “Plugins”) for fast access to the module tables.
Requirements
This plugin has been developed and tested on:
- NetBox: version
4.1.6 - Python: version
3.10.12or higher
While it may work on later NetBox versions, these are the ones used during development and testing. If you encounter any incompatibility, please open an issue.
Installation
Step 1: Install using pip
pip install inventory_viewer
Step 2: Add the plugin into PLUGINS array in configuration.py
PLUGINS = [
'inventory_viewer',
# Other plugins...
]
Step 3: Run netbox(for example)
python manage.py runserver
Usage
View Modules
-
In the NetBox main menu, find “Inventory Viewer” under the Plugins section.
-
The plugin automatically lists all modules in NetBox, grouped by module type (e.g., Silicom N5010, Silicom N6010, etc.).
-
Each module’s entry shows:
- Serial (SN)
- Custom Fields like “rok_zavedeni,” “merici_bod,” etc.
- Asset Tag (Ev. č.)
- Location (site, location, device)
- Cable Connections (includes connected interfaces or ports and where they lead)
- Notes (comments field)
Cable Connections
When a module is connected via front/rear ports or interfaces, the plugin displays a short summary describing each cable’s endpoints, for example:
DeviceA/Eth1 <-> DeviceB/Eth3
Custom Fields
If your NetBox instance has custom fields like “rok_zavedeni” or “merici_bod” defined for the dcim.Module model, those values automatically appear as columns in the module table.
Project Structure
inventory_viewer/
├── views.py # Transfer and linking logic
├── templates/ # HTML templates
├── urls.py # Plugin URLs
├── navigation.py # Plugin menu entries
└── tables.py/ # Custom table
Changelog
v1.0.1
- Plugin now shows cables which have only one termination (termination A)
- Added headers to each file
v1.0
- Initial release: Displays modules grouped by module type in tables
- Shows cable connections, device location, and custom fields
- Integrates directly into NetBox’s plugin menu
Notes
-
Non-Intrusive: This plugin does not override NetBox’s core behavior or templates. It only adds new pages and logic within the plugin framework.
-
Custom Fields: If you have not defined the custom fields (“rok_zavedeni”/“merici_bod”), you have to define them in your netbox instance, i tried to make this via python script but it didn't work. I defined rok_zavedeni as integer and merici_bod as text.
-
Cable Data: The plugin relies on standard dcim.Module relationships (frontports, rearports, interfaces). If a module’s device or ports are not set properly, the cable connection info may appear incomplete.
Author
Viktor Kubec
BUT FIT Brno student
MIT License
GitHub: vubeckubec/inventory_viewer
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file inventory_viewer-1.0.1.tar.gz.
File metadata
- Download URL: inventory_viewer-1.0.1.tar.gz
- Upload date:
- Size: 9.0 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.0.1 CPython/3.10.12
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
cdf301c4b0cb535acda0344f1bc80b2c7ab04fbc554f806f902576cea801fcf7
|
|
| MD5 |
0d3983248d78e51b5e990cac56556da9
|
|
| BLAKE2b-256 |
442a9ce5a1bac91acc380445668e7239337f12f8e853a5e8d23e01f20c9477af
|
File details
Details for the file inventory_viewer-1.0.1-py3-none-any.whl.
File metadata
- Download URL: inventory_viewer-1.0.1-py3-none-any.whl
- Upload date:
- Size: 9.3 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.0.1 CPython/3.10.12
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
ab74b948ce3d0a3bac6da890b298213480b27daa32fd217d8a84181495c77b3b
|
|
| MD5 |
4869b6cb385c5d22c285395375b1ed35
|
|
| BLAKE2b-256 |
b536fa6bcc380217e19e84078d27b44131dce37e4db06db84d4435fc7ceaf1c0
|