Convert power draw/max draw to PositiveIntegerField

This commit is contained in:
Austin de Coup-Crank 2023-05-12 13:38:49 -05:00
parent 39fd64b2ef
commit e76d64dacc
2 changed files with 4 additions and 4 deletions

View File

@ -232,13 +232,13 @@ class PowerPortTemplate(ModularComponentTemplateModel):
choices=PowerPortTypeChoices,
blank=True
)
maximum_draw = models.PositiveSmallIntegerField(
maximum_draw = models.PositiveIntegerField(
blank=True,
null=True,
validators=[MinValueValidator(1)],
help_text=_("Maximum power draw (watts)")
)
allocated_draw = models.PositiveSmallIntegerField(
allocated_draw = models.PositiveIntegerField(
blank=True,
null=True,
validators=[MinValueValidator(1)],

View File

@ -329,13 +329,13 @@ class PowerPort(ModularComponentModel, CabledObjectModel, PathEndpoint):
blank=True,
help_text=_('Physical port type')
)
maximum_draw = models.PositiveSmallIntegerField(
maximum_draw = models.PositiveIntegerField(
blank=True,
null=True,
validators=[MinValueValidator(1)],
help_text=_("Maximum power draw (watts)")
)
allocated_draw = models.PositiveSmallIntegerField(
allocated_draw = models.PositiveIntegerField(
blank=True,
null=True,
validators=[MinValueValidator(1)],