Add model-specific filters for cables #14434
Labels
status: accepted
This issue has been accepted for implementation
type: feature
Introduction of new functionality to the application
Milestone
NetBox version
v3.6.6
Feature type
New functionality
Proposed functionality
Add the following query filters for cables:
circuittermination
consoleport
consoleserverport
frontport
interface
powerfeed
poweroutlet
powerport
rearport
These filters can be used to easily filter for cables by their terminating object(s). For example,
GET /api/dcim/cables/?interface=123
will return the cable (if any) terminated to the interface with ID 123.It should be possible to pass multiple values effecting a logical OR, to allow returning all cables attached to any of the specified terminations, e.g.
GET /api/dcim/cables/?interface=123&interface=456&frontport=789
.Use case
This approach greatly simplifies filtering of cables by specific termination points. As noted in #14274, the current approach utilizing
termination_type
andtermination_id
filters is limited and error-prone.Database changes
None
External dependencies
None
The text was updated successfully, but these errors were encountered: