Better display for piggy bank events.

This commit is contained in:
James Cole 2015-07-24 08:34:30 +02:00
parent 50c13fd469
commit ba9601d21c
2 changed files with 8 additions and 4 deletions

View File

@ -19,6 +19,8 @@ return [
'never' => 'Never',
'search_results_for' => 'Search results for ":query"',
'bounce_error' => 'The message sent to :email bounced.',
'removed_amount' => 'Removed :amount',
'added_amount' => 'Added :amount',
// attachments
'nr_of_attachments' => 'One attachment|:count attachments',

View File

@ -16,17 +16,19 @@
<td>
{% if event.transaction_journal_id %}
<a href="{{ route('transactions.show',event.transaction_journal_id) }}"
title="{{ event.transactionJournal.description }}">{{ event.date.format('j F Y') }}</a>
title="{{ event.transactionJournal.description }}">{{ event.date.formatLocalized(monthAndDayFormat) }}</a>
{% else %}
{{ event.date.format('j F Y') }}
{{ event.date.formatLocalized(monthAndDayFormat) }}
{% endif %}
</td>
<td>
{% if event.amount < 0 %}
<span class="text-danger">Removed {{ event.amount*-1|formatAmountPlain }}</span>
<span class="text-danger">{{ trans('firefly.removed_amount', {amount: (event.amount*-1)|formatAmountPlain})|raw }}</span>
{% else %}
<span class="text-success">Added {{ event.amount|formatAmountPlain }}</span>
<span class="text-success">{{ trans('firefly.added_amount', {amount: (event.amount)|formatAmountPlain})|raw }}</span>
{% endif %}
</td>
</tr>