{% extends "ui/panels/_base.html" %} {% load helpers i18n %} {% block panel_content %} {% for powerport in object.powerports.all %} {% with utilization=powerport.get_power_draw powerfeed=powerport.connected_endpoints.0 %} {% if powerfeed.available_power %} {% else %} {% endif %} {% for leg in utilization.legs %} {% if powerfeed.available_power %} {% with phase_available=powerfeed.available_power|divide:3 %} {% endwith %} {% else %} {% endif %} {% endfor %} {% endwith %} {% endfor %}
{% trans "Input" %} {% trans "Outlets" %} {% trans "Allocated" %} {% trans "Available" %} {% trans "Utilization" %}
{{ powerport }} {{ utilization.outlet_count }} {{ utilization.allocated }}{% trans "VA" %}{{ powerfeed.available_power }}{% trans "VA" %} {% utilization_graph utilization.allocated|percentage:powerfeed.available_power %}
{% trans "Leg" context "Leg of a power feed" %} {{ leg.name }} {{ leg.outlet_count }} {{ leg.allocated }}{{ phase_available }}{% trans "VA" %} {% utilization_graph leg.allocated|percentage:phase_available %}
{% endblock panel_content %}