Add label to *ports models

This commit is contained in:
Jonathan Senecal
2020-06-05 10:32:59 -04:00
parent f8851121ab
commit a06d74472d
3 changed files with 93 additions and 0 deletions

View File

@@ -231,6 +231,11 @@ class ConsolePort(CableTermination, ComponentModel):
name = models.CharField(
max_length=50
)
label = models.CharField(
max_length=64,
blank=True,
help_text="The physical label for this console port"
)
_name = NaturalOrderingField(
target_field='name',
max_length=100,
@@ -298,6 +303,11 @@ class ConsoleServerPort(CableTermination, ComponentModel):
max_length=100,
blank=True
)
label = models.CharField(
max_length=64,
blank=True,
help_text="The physical label for this console server port"
)
type = models.CharField(
max_length=50,
choices=ConsolePortTypeChoices,
@@ -353,6 +363,11 @@ class PowerPort(CableTermination, ComponentModel):
max_length=100,
blank=True
)
label = models.CharField(
max_length=64,
blank=True,
help_text="The physical label for this power supply port"
)
type = models.CharField(
max_length=50,
choices=PowerPortTypeChoices,
@@ -516,6 +531,11 @@ class PowerOutlet(CableTermination, ComponentModel):
max_length=100,
blank=True
)
label = models.CharField(
max_length=64,
blank=True,
help_text="The physical label for this power outlet"
)
type = models.CharField(
max_length=50,
choices=PowerOutletTypeChoices,