mirror of
https://github.com/firefly-iii/firefly-iii.git
synced 2025-10-12 15:35:15 +00:00
Code improvements for budgets.
This commit is contained in:
@@ -459,8 +459,11 @@ return [
|
||||
'store_new_budget' => 'Store new budget',
|
||||
'stored_new_budget' => 'Stored new budget ":name"',
|
||||
'availableIn' => 'Available in :date',
|
||||
'available_between' => 'Available between :start and :end',
|
||||
'transactionsWithoutBudget' => 'Expenses without budget',
|
||||
'transactionsWithoutBudgetDate' => 'Expenses without budget in :date',
|
||||
'transactions_no_budget' => 'Expenses without budget between :start and :end',
|
||||
'spent_between' => 'Spent between :start and :end',
|
||||
'createBudget' => 'New budget',
|
||||
'inactiveBudgets' => 'Inactive budgets',
|
||||
'without_budget_between' => 'Transactions without a budget between :start and :end',
|
||||
|
@@ -9,7 +9,7 @@
|
||||
<div class="col-lg-9 col-sm-8 col-md-8">
|
||||
<div class="box">
|
||||
<div class="box-header with-border">
|
||||
<h3 class="box-title">{{ Session.get('start').formatLocalized(monthFormat) }}</h3>
|
||||
<h3 class="box-title">{{ periodStart }} — {{ periodEnd }}</h3>
|
||||
|
||||
<!-- ACTIONS MENU -->
|
||||
<div class="box-tools pull-right">
|
||||
@@ -23,7 +23,7 @@
|
||||
<small>{{ 'budgeted'|_ }}: <span id="budgetedAmount" class="text-success">{{ budgeted|formatAmountPlain }}</span></small>
|
||||
</div>
|
||||
<div class="col-lg-6 col-md-4 col-sm-3" style="text-align:right;">
|
||||
<small>{{ trans('firefly.availableIn',{date : period }) }}:
|
||||
<small>{{ trans('firefly.available_between',{start : periodStart, end: periodEnd }) }}:
|
||||
<a href="#" class="updateIncome"><span id="budgetIncomeTotal"
|
||||
data-value="{{ budgetIncomeTotal }}">{{ budgetIncomeTotal|formatAmount }}</span></a>
|
||||
</small>
|
||||
@@ -44,7 +44,7 @@
|
||||
</div>
|
||||
<div class="row">
|
||||
<div class="col-lg-6 col-md-4 col-sm-3">
|
||||
<small>{{ 'spent'|_ }}: {{ spent|formatAmount }}</small>
|
||||
<small>{{ trans('firefly.spent_between', {start: periodStart, end: periodEnd}) }}: {{ spent|formatAmount }}</small>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row">
|
||||
@@ -77,7 +77,7 @@
|
||||
<div class="box-body">
|
||||
<p>
|
||||
<a href="{{ route('budgets.noBudget') }}">
|
||||
{{ trans('firefly.transactionsWithoutBudgetDate', {date: period|lower }) }}
|
||||
{{ trans('firefly.transactions_no_budget', {start: periodStart, end: periodEnd }) }}
|
||||
</a>
|
||||
</p>
|
||||
</div>
|
||||
@@ -99,7 +99,6 @@
|
||||
|
||||
</div>
|
||||
</div>
|
||||
<p>Bla bla bla</p>
|
||||
<div class="row">
|
||||
{% for budget in budgets %}
|
||||
<div class="col-lg-4 col-sm-6 col-md-6">
|
||||
@@ -132,7 +131,7 @@
|
||||
<tr>
|
||||
<td style="width:40%;">
|
||||
{{ 'budgeted'|_ }}
|
||||
<span class="small"><br />
|
||||
<span class="small"><br/>
|
||||
{{ session('start').formatLocalized(monthAndDayFormat) }} -
|
||||
{{ session('end').formatLocalized(monthAndDayFormat) }}</span>
|
||||
</td>
|
||||
@@ -160,35 +159,43 @@
|
||||
<tr>
|
||||
<td style="width:40%;">
|
||||
{{ 'spent'|_ }}
|
||||
<span class="small"><br />
|
||||
<span class="small"><br/>
|
||||
{{ session('start').formatLocalized(monthAndDayFormat) }} -
|
||||
{{ session('end').formatLocalized(monthAndDayFormat) }}
|
||||
</span>
|
||||
</td>
|
||||
<td>{{ budget.spent|formatAmount }}</a></td>
|
||||
</tr>
|
||||
<!--
|
||||
<tr>
|
||||
<td style="width:40%">
|
||||
<span class="text-danger">
|
||||
Conflicts
|
||||
</span>
|
||||
</td>
|
||||
<td>
|
||||
<ul class="list-unstyled">
|
||||
<li>Also budgeted {{ 123|formatAmount }} between x and y.</li>
|
||||
<li>Also budgeted {{ 123|formatAmount }} between x and y.</li>
|
||||
</ul>
|
||||
</td>
|
||||
</tr>
|
||||
-->
|
||||
{% if budget.otherRepetitions.count > 0 %}
|
||||
<tr>
|
||||
<td colspan="2">
|
||||
<ul class="list-unstyled">
|
||||
{% for other in budget.otherRepetitions %}
|
||||
{% if other.id != budget.currentRep.id %}
|
||||
<li>Budgeted
|
||||
<a href="{{ route('budgets.show', [budget.id, other.id]) }}">{{ other.amount|formatAmountPlain }}</a>
|
||||
between
|
||||
{{ other.startdate.formatLocalized(monthAndDayFormat) }}
|
||||
and {{ other.enddate.formatLocalized(monthAndDayFormat) }}.
|
||||
</li>
|
||||
{% endif %}
|
||||
{% endfor %}
|
||||
</ul>
|
||||
</td>
|
||||
</tr>
|
||||
{% endif %}
|
||||
</table>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
{% if loop.index % 3 == 0 %}
|
||||
</div><div class="row">
|
||||
{% endif %}
|
||||
{% endfor %}
|
||||
</div>
|
||||
|
||||
{% if inactive|length > 0 %}
|
||||
{% if inactive|length > 0 %}
|
||||
<div class="row">
|
||||
<div class="col-lg-3 col-sm-4 col-md-6">
|
||||
<div class="box">
|
||||
<div class="box-header with-border">
|
||||
@@ -209,8 +216,8 @@
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
{% endif %}
|
||||
</div>
|
||||
</div>
|
||||
{% endif %}
|
||||
{% endblock %}
|
||||
{% block scripts %}
|
||||
<script type="text/javascript">
|
||||
|
Reference in New Issue
Block a user