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

PowerFeed.type to slug (#3569)

This commit is contained in:
Jeremy Stretch
2019-11-25 21:03:11 -05:00
parent 9872a46583
commit 62494f295e
7 changed files with 73 additions and 24 deletions

View File

@@ -872,3 +872,23 @@ class CableLengthUnitChoices(ChoiceSet):
UNIT_FOOT: 2100,
UNIT_INCH: 2000,
}
#
# PowerFeeds
#
class PowerFeedTypeChoices(ChoiceSet):
TYPE_PRIMARY = 'primary'
TYPE_REDUNDANT = 'redundant'
CHOICES = (
(TYPE_PRIMARY, 'Primary'),
(TYPE_REDUNDANT, 'Redundant'),
)
LEGACY_MAP = {
TYPE_PRIMARY: 1,
TYPE_REDUNDANT: 2,
}