2016-11-20 19:11:10 +01:00
|
|
|
<table class="table table-hover sortable">
|
2016-10-30 18:29:26 +01:00
|
|
|
<thead>
|
|
|
|
|
<tr>
|
2016-11-20 19:11:10 +01:00
|
|
|
<th data-defaultsign="az">{{ 'budget'|_ }}</th>
|
|
|
|
|
<th data-defaultsign="month" class="hidden-xs">{{ 'date'|_ }}</th>
|
2017-01-02 21:04:17 +01:00
|
|
|
<th data-defaultsign="_19" style="text-align: right;">{{ 'budgeted'|_ }}</th>
|
|
|
|
|
<th data-defaultsign="_19" style="text-align: right;">{{ 'spent'|_ }}</th>
|
|
|
|
|
<th data-defaultsort="disabled"> </th>
|
|
|
|
|
<th data-defaultsign="_19" style="text-align: right;">{{ 'left'|_ }}</th>
|
|
|
|
|
<th data-defaultsign="_19" style="text-align: right;">{{ 'overspent'|_ }}</th>
|
2016-10-30 18:29:26 +01:00
|
|
|
</tr>
|
|
|
|
|
</thead>
|
|
|
|
|
<tbody>
|
|
|
|
|
{% for budgetLine in budgets.getBudgetLines %}
|
|
|
|
|
<tr>
|
2016-11-20 19:11:10 +01:00
|
|
|
|
|
|
|
|
{% if budgetLine.getBudget.id %}
|
|
|
|
|
<td data-value="{{ budgetLine.getBudget.name }}">
|
2016-10-30 18:29:26 +01:00
|
|
|
<a href="{{ route('budgets.show',budgetLine.getBudget.id) }}">{{ budgetLine.getBudget.name }}</a>
|
2016-11-20 19:11:10 +01:00
|
|
|
</td>
|
|
|
|
|
{% else %}
|
|
|
|
|
<td data-value="zzzzzzz">
|
2016-10-30 18:29:26 +01:00
|
|
|
<em>{{ 'no_budget'|_ }}</em>
|
2016-11-20 19:11:10 +01:00
|
|
|
</td>
|
|
|
|
|
{% endif %}
|
|
|
|
|
|
|
|
|
|
|
2016-12-30 08:41:48 +01:00
|
|
|
{% if budgetLine.getBudgetLimit.id %}
|
|
|
|
|
<td class="hidden-xs" data-value="{{ budgetLine.getBudgetLimit.start_date.format('Y-m-d') }}">
|
|
|
|
|
<a href="{{ route('budgets.show.limit', [budgetLine.getBudget.id, budgetLine.getBudgetLimit.id]) }}">
|
|
|
|
|
{{ budgetLine.getBudgetLimit.start_date.formatLocalized(monthAndDayFormat) }}
|
2016-10-30 18:29:26 +01:00
|
|
|
—
|
2016-12-30 08:41:48 +01:00
|
|
|
{{ budgetLine.getBudgetLimit.end_date.formatLocalized(monthAndDayFormat) }}
|
2016-10-30 18:29:26 +01:00
|
|
|
</a>
|
2016-11-20 19:11:10 +01:00
|
|
|
</td>
|
|
|
|
|
{% else %}
|
|
|
|
|
<td data-value="0000-00-00">
|
|
|
|
|
|
|
|
|
|
</td>
|
|
|
|
|
{% endif %}
|
|
|
|
|
|
|
|
|
|
|
2016-12-30 08:41:48 +01:00
|
|
|
{% if budgetLine.getBudgetLimit.id %}
|
2017-01-02 21:04:17 +01:00
|
|
|
<td data-value="{{ budgetLine.getBudgetLimit.amount }}" style="text-align: right;">
|
2016-12-30 08:41:48 +01:00
|
|
|
{{ budgetLine.getBudgetLimit.amount|formatAmount }}
|
2016-11-20 19:11:10 +01:00
|
|
|
</td>
|
|
|
|
|
{% else %}
|
2017-01-02 21:04:17 +01:00
|
|
|
<td data-value="0" style="text-align: right;">
|
2016-10-30 18:29:26 +01:00
|
|
|
{{ 0|formatAmount }}
|
2016-11-20 19:11:10 +01:00
|
|
|
</td>
|
|
|
|
|
{% endif %}
|
|
|
|
|
|
2017-01-02 21:04:17 +01:00
|
|
|
<td data-value="{{ budgetLine.getSpent }}" style="text-align: right;">
|
2016-10-30 18:29:26 +01:00
|
|
|
{% if budgetLine.getSpent != 0 %}
|
2016-11-20 19:11:10 +01:00
|
|
|
{{ budgetLine.getSpent|formatAmount }}
|
2017-01-02 21:04:17 +01:00
|
|
|
<!-- <i class="fa fa-fw text-muted fa-info-circle firefly-info-button"
|
2016-11-20 19:11:10 +01:00
|
|
|
data-location="budget-spent-amount" data-budget-id="{{ budgetLine.getBudget.id }}"></i>
|
2017-01-02 21:04:17 +01:00
|
|
|
-->
|
2016-10-30 18:29:26 +01:00
|
|
|
{% endif %}
|
2015-05-16 14:14:22 +02:00
|
|
|
|
2016-10-30 18:29:26 +01:00
|
|
|
{% if budgetLine.getSpent == 0 %}
|
|
|
|
|
{{ budgetLine.getSpent|formatAmount }}
|
|
|
|
|
{% endif %}
|
2017-01-02 21:04:17 +01:00
|
|
|
</td>
|
|
|
|
|
<td>
|
|
|
|
|
{% if budgetLine.getSpent != 0 %}
|
|
|
|
|
<i class="fa fa-fw text-muted fa-info-circle firefly-info-button"
|
|
|
|
|
data-location="budget-spent-amount" data-budget-id="{{ budgetLine.getBudget.id }}"></i>
|
2015-12-02 08:33:22 +01:00
|
|
|
|
2017-01-02 21:04:17 +01:00
|
|
|
{% endif %}
|
2016-10-30 18:29:26 +01:00
|
|
|
</td>
|
2017-01-02 21:04:17 +01:00
|
|
|
|
|
|
|
|
<td data-value="{{ budgetLine.getLeft }}" style="text-align: right;">
|
2016-10-30 18:29:26 +01:00
|
|
|
{% if(budgetLine.getOverspent == 0) %}
|
|
|
|
|
{{ budgetLine.getLeft|formatAmount }}
|
|
|
|
|
{% endif %}
|
|
|
|
|
</td>
|
2017-01-02 21:04:17 +01:00
|
|
|
<td data-value="{{ budgetLine.getOverspent }}" style="text-align: right;">
|
2016-10-30 18:29:26 +01:00
|
|
|
{% if budgetLine.getOverspent != 0 %}
|
|
|
|
|
{{ budgetLine.getOverspent|formatAmount }}
|
|
|
|
|
{% endif %}
|
|
|
|
|
</td>
|
|
|
|
|
</tr>
|
|
|
|
|
{% endfor %}
|
|
|
|
|
</tbody>
|
|
|
|
|
<tfoot>
|
|
|
|
|
<tr>
|
2016-11-08 20:35:30 +01:00
|
|
|
<td><em>{{ 'sum'|_ }}</em></td>
|
|
|
|
|
<td class="hidden-xs"> </td>
|
2017-01-02 21:04:17 +01:00
|
|
|
<td style="text-align: right;">{{ budgets.getBudgeted|formatAmount }}</td>
|
|
|
|
|
<td style="text-align: right;">
|
2016-10-30 18:29:26 +01:00
|
|
|
{% if budgets.getSpent != 0 %}
|
|
|
|
|
<span class="text-danger">{{ budgets.getSpent|formatAmountPlain }}</span>
|
|
|
|
|
{% endif %}
|
|
|
|
|
{% if budgets.getSpent == 0 %}
|
|
|
|
|
{{ budgets.getSpent|formatAmount }}
|
|
|
|
|
{% endif %}
|
|
|
|
|
</td>
|
2017-01-02 21:04:17 +01:00
|
|
|
<td> </td>
|
|
|
|
|
<td style="text-align: right;">{{ budgets.getLeft|formatAmount }}</td>
|
|
|
|
|
<td style="text-align: right;"><span class="text-danger">{{ budgets.getOverspent|formatAmountPlain }}</span></td>
|
2016-10-30 18:29:26 +01:00
|
|
|
</tr>
|
|
|
|
|
</tfoot>
|
|
|
|
|
</table>
|