81 lines
2.8 KiB
HTML
81 lines
2.8 KiB
HTML
{% from "components/accordion.html" import Accordion %}
|
|
{% from "components/empty_state.html" import EmptyState %}
|
|
{% from "components/icon.html" import Icon %}
|
|
{% from "components/sticky_cta.html" import StickyCTA %}
|
|
|
|
{% extends "portfolios/base.html" %}
|
|
|
|
{% block portfolio_content %}
|
|
|
|
{% macro TaskOrderDateTime(dt, className="") %}
|
|
<local-datetime timestamp="{{ dt }}" format="MMMM D, YYYY" class="{{ className }}"></local-datetime>
|
|
{% endmacro %}
|
|
|
|
|
|
{% macro TaskOrderList(task_orders, status) %}
|
|
<div class="accordion usa-accordion">
|
|
{% call Accordion(title=status, id=status, heading_tag="h4") %}
|
|
{% for task_order in task_orders %}
|
|
<div class="accordion__content--list-item">
|
|
<h4><a href="{{ url_for('task_orders.review_task_order', task_order_id=task_order.id) }}">Task Order #{{ task_order.number }} {{ Icon("caret_right", classes="icon--tiny icon--primary" ) }}</a></h4>
|
|
<div class="row">
|
|
<div class="col col--grow">
|
|
<h5>
|
|
Current Period of Performance
|
|
</h5>
|
|
<p>
|
|
{{ task_order.start_date | formattedDate(formatter="%b %d, %Y") }}
|
|
-
|
|
{{ task_order.end_date | formattedDate(formatter="%b %d, %Y") }}
|
|
</p>
|
|
</div>
|
|
<div class="col col--grow">
|
|
<h5>Total Value</h5>
|
|
<p>{{ task_order.total_contract_amount | dollars }}</p>
|
|
</div>
|
|
<div class="col col--grow">
|
|
<h5>Total Obligated</h5>
|
|
<p>{{ task_order.total_obligated_funds | dollars }}</p>
|
|
</div>
|
|
<div class="col col--grow">
|
|
<h5>Total Expended</h5>
|
|
<p>$0</p>
|
|
</div>
|
|
</div>
|
|
</div>
|
|
{% endfor %}
|
|
{% endcall %}
|
|
</div>
|
|
{% endmacro %}
|
|
|
|
|
|
{% call StickyCTA(text="common.task_orders"|translate) %}
|
|
{% if user_can(permissions.CREATE_TASK_ORDER) and task_orders %}
|
|
<a href="{{ url_for("task_orders.form_step_one_add_pdf", portfolio_id=portfolio.id) }}" class="usa-button usa-button-primary">
|
|
{{ "task_orders.add_new_button" | translate }}
|
|
</a>
|
|
{% endif %}
|
|
{% endcall %}
|
|
|
|
{% include "fragments/flash.html" %}
|
|
|
|
<div class="portfolio-funding">
|
|
|
|
{% if task_orders %}
|
|
{% for status, to_list in task_orders.items() %}
|
|
{{ TaskOrderList(to_list, status.value) }}
|
|
{% endfor %}
|
|
{% else %}
|
|
{{ EmptyState(
|
|
header="task_orders.empty_state.header"|translate,
|
|
message="task_orders.empty_state.message"|translate,
|
|
button_link=url_for('task_orders.form_step_one_add_pdf', portfolio_id=portfolio.id),
|
|
button_text="task_orders.empty_state.button_text"|translate,
|
|
view_only_text="task_orders.empty_state.view_only_text"|translate,
|
|
user_can_create=user_can(permissions.CREATE_TASK_ORDER),
|
|
) }}
|
|
{% endif %}
|
|
</div>
|
|
|
|
{% endblock %}
|