Merge pull request #629 from dod-ccpo/funding-header

Add Funding Through to Portfolio Header
This commit is contained in:
montana-mil
2019-02-12 14:27:02 -05:00
committed by GitHub
5 changed files with 104 additions and 17 deletions

View File

@@ -15,14 +15,41 @@
{{ secondary_breadcrumb or portfolio.name }}
</div>
<div class='portfolio-header__budget row'>
<span>Available budget</span>
<button type="button" tabindex="0" class="icon-tooltip" v-tooltip.right="{content: 'The available budget shown includes the available budget of all active task orders', container: false}">
{{ Icon('info') }}
</button>
<span class='portfolio-header__budget--dollars'>
{{ portfolio.task_orders | selectattr('is_active') | sum(attribute='budget') | dollars }}
</span>
<div class='column-left'>
<span>Available budget</span>
<button type="button" tabindex="0" class="icon-tooltip" v-tooltip.right="{content: 'The available budget shown includes the available budget of all active task orders', container: false}">
{{ Icon('info') }}
</button>
</div>
<div>
<span class='portfolio-header__budget--dollars'>
{{ portfolio.task_orders | selectattr('is_active') | sum(attribute='budget') | justDollars }}
</span>
<span class='cents'>
.{{ portfolio.task_orders | selectattr('is_active') | sum(attribute='budget') | justCents }}
</span>
</div>
</div>
<div class='row'>
<div class='column-left'></div>
<div class='column-right portfolio-funding__header--funded-through {{ "funded" if funding_end_date is not none and funded else "unfunded"}}'>
{% if funding_end_date and funded %}
{{ Icon('ok') }}
Funded through
<local-datetime
timestamp='{{ funding_end_date }}'
format="M/D/YYYY">
</local-datetime>
{% elif funding_end_date and not funded %}
{{ Icon('alert') }}
Funded period ends
<local-datetime
timestamp='{{ funding_end_date }}'
format="M/D/YYYY">
</local-datetime>
{% endif %}
</div>
</div>
</div>
<div class='row links'>
{% if user_can(permissions.VIEW_USAGE_DOLLARS) %}