1
0
mirror of https://github.com/netbox-community/netbox.git synced 2024-05-10 07:54:54 +00:00

Closes #10371: Add operational status field for modules

This commit is contained in:
jeremystretch
2022-12-09 10:43:29 -05:00
parent b2f34cec19
commit 97aa40f7a8
17 changed files with 123 additions and 29 deletions

View File

@@ -194,6 +194,30 @@ class DeviceAirflowChoices(ChoiceSet):
)
#
# Modules
#
class ModuleStatusChoices(ChoiceSet):
key = 'Module.status'
STATUS_OFFLINE = 'offline'
STATUS_ACTIVE = 'active'
STATUS_PLANNED = 'planned'
STATUS_STAGED = 'staged'
STATUS_FAILED = 'failed'
STATUS_DECOMMISSIONING = 'decommissioning'
CHOICES = [
(STATUS_OFFLINE, 'Offline', 'gray'),
(STATUS_ACTIVE, 'Active', 'green'),
(STATUS_PLANNED, 'Planned', 'cyan'),
(STATUS_STAGED, 'Staged', 'blue'),
(STATUS_FAILED, 'Failed', 'red'),
(STATUS_DECOMMISSIONING, 'Decommissioning', 'yellow'),
]
#
# ConsolePorts
#