{% extends "modal_form.html" %}
{% load i18n %}

{% block pre_form_content %}

{% if build.can_complete %}
<div class='alert alert-block alert-success'>
    {% trans "Build Order is complete" %}
</div>
{% else %}
<div class='alert alert-block alert-danger'>
    <strong>{% trans "Build Order is incomplete" %}</strong><br>
    <ul>
        {% if build.incomplete_count > 0 %}
        <li>{% trans "Incompleted build outputs remain" %}</li>
        {% endif %}
        {% if build.completed < build.quantity %}
        <li>{% trans "Required build quantity has not been completed" %}</li>
        {% endif %}
        {% if not build.areUntrackedPartsFullyAllocated %}
        <li>{% trans "Required stock has not been fully allocated" %}</li>
        {% endif %}
    </ul>
</div>
{% endif %}
{% endblock %}