Fixes #3136: Add power draw fields to power port creation form

This commit is contained in:
Jeremy Stretch 2019-05-02 10:02:02 -04:00
parent 250f310a98
commit d4db04c649
2 changed files with 11 additions and 0 deletions

View File

@ -6,6 +6,7 @@ v2.6.0 (FUTURE)
* [#3125](https://github.com/digitalocean/netbox/issues/3125) - Fix exception when viewing PDUs * [#3125](https://github.com/digitalocean/netbox/issues/3125) - Fix exception when viewing PDUs
* [#3126](https://github.com/digitalocean/netbox/issues/3126) - Incorrect calculation of PowerFeed available power * [#3126](https://github.com/digitalocean/netbox/issues/3126) - Incorrect calculation of PowerFeed available power
* [#3130](https://github.com/digitalocean/netbox/issues/3130) - Fix exception when creating a new power outlet * [#3130](https://github.com/digitalocean/netbox/issues/3130) - Fix exception when creating a new power outlet
* [#3136](https://github.com/digitalocean/netbox/issues/3136) - Add power draw fields to power port creation form
--- ---

View File

@ -1971,6 +1971,16 @@ class PowerPortCreateForm(ComponentForm):
name_pattern = ExpandableNameField( name_pattern = ExpandableNameField(
label='Name' label='Name'
) )
maximum_draw = forms.IntegerField(
min_value=1,
required=False,
help_text="Maximum draw in watts"
)
allocated_draw = forms.IntegerField(
min_value=1,
required=False,
help_text="Allocated draw in watts"
)
description = forms.CharField( description = forms.CharField(
max_length=100, max_length=100,
required=False required=False