mirror of
https://github.com/netbox-community/netbox.git
synced 2024-05-10 07:54:54 +00:00
Added a status field for virtual machines
This commit is contained in:
19
netbox/virtualization/constants.py
Normal file
19
netbox/virtualization/constants.py
Normal file
@@ -0,0 +1,19 @@
|
||||
from __future__ import unicode_literals
|
||||
|
||||
|
||||
# VirtualMachine statuses (replicated from Device statuses)
|
||||
STATUS_OFFLINE = 0
|
||||
STATUS_ACTIVE = 1
|
||||
STATUS_STAGED = 3
|
||||
STATUS_CHOICES = [
|
||||
[STATUS_ACTIVE, 'Active'],
|
||||
[STATUS_OFFLINE, 'Offline'],
|
||||
[STATUS_STAGED, 'Staged'],
|
||||
]
|
||||
|
||||
# Bootstrap CSS classes for VirtualMachine statuses
|
||||
VM_STATUS_CLASSES = {
|
||||
0: 'warning',
|
||||
1: 'success',
|
||||
3: 'primary',
|
||||
}
|
||||
Reference in New Issue
Block a user