Device Platform selection is not limited by Manufacturer #8751

Closed
opened 2025-12-29 20:40:46 +01:00 by adam · 3 comments
Owner

Originally created by @sleepinggenius2 on GitHub (Oct 17, 2023).

Originally assigned to: @DanSheps on GitHub.

NetBox version

v3.6.3

Python version

3.8

Steps to Reproduce

Device
  1. Click on "Devices" > "Add"
  2. Select a "Device type" under the "Hardware" section
  3. Click on the "Platform" dropdown under the "Management" section
  4. The list includes all Platform values
Device Type
  1. Click on "Device Types" > "Add"
  2. Select a "Manufacturer" under the "Device Type" section
  3. Click on the "Default platform" dropdown under the "Device Type" section
  4. The list includes all Platform values

Expected Behavior

The available list of platforms should be limited by the selected manufacturer.

Observed Behavior

All Platform objects are available for selection.

It looks like when #11952 was implemented it caused a regression in how this worked for Devices, as the Manufacturer was previously filtered on in the UI. There is still a check in place on the Device.clean method to perform this validation, so it seems to just be a UI bug for Devices at this time.

For Device Types, it does not appear that filtering or validation were ever added for the default_platform field.

Originally created by @sleepinggenius2 on GitHub (Oct 17, 2023). Originally assigned to: @DanSheps on GitHub. ### NetBox version v3.6.3 ### Python version 3.8 ### Steps to Reproduce ##### Device 1. Click on "Devices" > "Add" 2. Select a "Device type" under the "Hardware" section 3. Click on the "Platform" dropdown under the "Management" section 4. The list includes all Platform values ##### Device Type 1. Click on "Device Types" > "Add" 2. Select a "Manufacturer" under the "Device Type" section 3. Click on the "Default platform" dropdown under the "Device Type" section 4. The list includes all Platform values ### Expected Behavior The available list of platforms should be limited by the selected manufacturer. ### Observed Behavior All Platform objects are available for selection. It looks like when #11952 was implemented it caused a regression in how this worked for Devices, as the Manufacturer was previously filtered on in the UI. There is still a check in place on the `Device.clean` method to perform this validation, so it seems to just be a UI bug for Devices at this time. For Device Types, it does not appear that filtering or validation were ever added for the `default_platform` field.
adam added the type: bugstatus: acceptedseverity: low labels 2025-12-29 20:40:46 +01:00
adam closed this issue 2025-12-29 20:40:46 +01:00
Author
Owner

@cpmills1975 commented on GitHub (Nov 14, 2023):

I'd like to vote against this unless the filter allows platforms with no manufacturer to be included.

While a network switch OS is only ever going to be run on a switch from the same manufacturer, the same cannot be said for server OSs such as Linux that will run happily on a Dell just as it will on a HP.

The Devices clean method takes care of this through checking for a manufacturer field in the platform and only rejecting the platform if these differ. Unless the UI can do the same, then this shouldn't be 'fixed'.

@cpmills1975 commented on GitHub (Nov 14, 2023): I'd like to vote against this unless the filter allows platforms with no manufacturer to be included. While a network switch OS is only ever going to be run on a switch from the same manufacturer, the same cannot be said for server OSs such as Linux that will run happily on a Dell just as it will on a HP. The Devices clean method takes care of this through checking for a manufacturer field in the platform and only rejecting the platform if these differ. Unless the UI can do the same, then this shouldn't be 'fixed'.
Author
Owner

@sleepinggenius2 commented on GitHub (Nov 14, 2023):

Yes, the filter previously included platforms with no manufacturer set. I would just like to have pre-3.5 functionality restored in the UI for devices at a minimum. The Device Type functionality would actually be easier to implement, as it still has the Manufacturer field, it just looks like it was never implemented when the default_platform field was added. From a UX standpoint, if I have a Cisco device, I should see IOS, but not Junos listed, and I might still have something like Linux listed (no manufacturer set). This is how it worked in 3.4, before we lost the Manufacturer field, when it was incorporated into the object selector for the Device Type.

@sleepinggenius2 commented on GitHub (Nov 14, 2023): Yes, the filter previously included platforms with no manufacturer set. I would just like to have pre-3.5 functionality restored in the UI for devices at a minimum. The Device Type functionality would actually be easier to implement, as it still has the Manufacturer field, it just looks like it was never implemented when the default_platform field was added. From a UX standpoint, if I have a Cisco device, I should see IOS, but not Junos listed, and I might still have something like Linux listed (no manufacturer set). This is how it worked in 3.4, before we lost the Manufacturer field, when it was incorporated into the object selector for the Device Type.
Author
Owner

@Katharta commented on GitHub (Dec 9, 2023):

Agree with cpmills1975... I would like to notate the manufacturer for server OSes for inventory purposes, but locking the available device types to said manufacturer ideally should be a separate option or checkbox.

@Katharta commented on GitHub (Dec 9, 2023): Agree with cpmills1975... I would like to notate the manufacturer for server OSes for inventory purposes, but locking the available device types to said manufacturer ideally should be a separate option or checkbox.
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: starred/netbox#8751