Skip to content

Device_count is not updated on device roles if a device is removed/add to the role #3672

@soer7022

Description

@soer7022

Environment

  • Python version: v3.6.8
  • NetBox version: v2.6.5

Steps to Reproduce

  1. Create a new device role
  2. Add an existing device to it
  3. Check the api response on device_count
  4. Remove the device from it
  5. Check the api response on device_count

Expected Behavior

I expect the device_count to be correctly updated

Observed Behavior

When adding an existing device to the role, the role's device_count stays at null.
When a new device is created and added to the role directly, the device_count is still null.

Metadata

Metadata

Assignees

No one assigned

    Labels

    status: acceptedThis issue has been accepted for implementationtype: bugA confirmed report of unexpected behavior in the application

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions