{% 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 ViewLink(task_order) %} View {{ Icon("caret_right", classes="icon--tiny") }} {% endmacro %} {% macro TaskOrderDate(task_order) %} {% if task_order.is_active %} Began {{ task_order.start_date }}   |   Ends {{ task_order.end_date }} {% elif task_order.is_expired %} Started {{ task_order.start_date }}   |   Ended {{ task_order.end_date }} {% else %} Started {{ task_order.start_date }} {% endif %} {% endmacro %} {% macro TaskOrderList(task_orders) %}
{% for task_order in task_orders %}
{{ task_order.display_status }} {{ TaskOrderDate(task_order) }}

Task Order {{ task_order.number }}

This is a TO description. This is a TO description. This is a TO description. This is a TO description. This is a TO description. This is a TO description.
{% endfor %}
{% endmacro %}
{% call StickyCTA(text="Funding") %}
Start a new task order
{% endcall %} {% for task_order in pending_task_orders %}
Pending
Pending
Started
Value
{{ task_order.budget | dollars }}
{{ ViewLink(task_order) }}
{% endfor %} {% if not active_task_orders and not pending_task_orders %} {{ EmptyState( 'This portfolio doesn’t have any active or pending task orders.', action_label='Add a New Task Order', action_href=url_for('task_orders.edit', portfolio_id=portfolio.id), icon='cloud', ) }} {% endif %} {% if active_task_orders %} {{ TaskOrderList(active_task_orders) }} {% endif %} {% if expired_task_orders %} {{ TaskOrderList(expired_task_orders) }} {% endif %}
{% endblock %}