mirror of
https://github.com/netbox-community/netbox.git
synced 2024-05-10 07:54:54 +00:00
Fixes #5584: Restore power utilization panel under device view
This commit is contained in:
@ -1,5 +1,13 @@
|
|||||||
# NetBox v2.10
|
# NetBox v2.10
|
||||||
|
|
||||||
|
## v2.10.4 (FUTURE)
|
||||||
|
|
||||||
|
### Bug Fixes
|
||||||
|
|
||||||
|
* [#5584](https://github.com/netbox-community/netbox/issues/5584) - Restore power utilization panel under device view
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
## v2.10.3 (2021-01-05)
|
## v2.10.3 (2021-01-05)
|
||||||
|
|
||||||
### Bug Fixes
|
### Bug Fixes
|
||||||
|
@ -204,7 +204,7 @@
|
|||||||
{% plugin_left_page object %}
|
{% plugin_left_page object %}
|
||||||
</div>
|
</div>
|
||||||
<div class="col-md-6">
|
<div class="col-md-6">
|
||||||
{% if power_ports and poweroutlets %}
|
{% if object.powerports.exists and object.poweroutlets.exists %}
|
||||||
<div class="panel panel-default">
|
<div class="panel panel-default">
|
||||||
<div class="panel-heading">
|
<div class="panel-heading">
|
||||||
<strong>Power Utilization</strong>
|
<strong>Power Utilization</strong>
|
||||||
@ -217,10 +217,10 @@
|
|||||||
<th>Available</th>
|
<th>Available</th>
|
||||||
<th>Utilization</th>
|
<th>Utilization</th>
|
||||||
</tr>
|
</tr>
|
||||||
{% for pp in power_ports %}
|
{% for powerport in object.powerports.all %}
|
||||||
{% with utilization=pp.get_power_draw powerfeed=pp.connected_endpoint %}
|
{% with utilization=powerport.get_power_draw powerfeed=powerport.connected_endpoint %}
|
||||||
<tr>
|
<tr>
|
||||||
<td>{{ pp }}</td>
|
<td>{{ powerport }}</td>
|
||||||
<td>{{ utilization.outlet_count }}</td>
|
<td>{{ utilization.outlet_count }}</td>
|
||||||
<td>{{ utilization.allocated }}VA</td>
|
<td>{{ utilization.allocated }}VA</td>
|
||||||
{% if powerfeed.available_power %}
|
{% if powerfeed.available_power %}
|
||||||
|
Reference in New Issue
Block a user