firefly-iii/app/views/transactions/journals-small-noaccount.blade.php
2014-09-27 06:06:31 +02:00

33 lines
1.1 KiB
PHP

<div class="list-group">
@foreach($transactions as $journal)
<a class="list-group-item" title="{{$journal->date->format('jS M Y')}}" href="{{route('transactions.show',$journal->id)}}">
@if($journal->transactiontype->type == 'Withdrawal')
<i class="fa fa-long-arrow-left fa-fw" title="Withdrawal"></i>
@endif
@if($journal->transactiontype->type == 'Deposit')
<i class="fa fa-long-arrow-right fa-fw" title="Deposit"></i>
@endif
@if($journal->transactiontype->type == 'Transfer')
<i class="fa fa-arrows-h fa-fw" title="Transfer"></i>
@endif
{{{$journal->description}}}
<span class="pull-right small">
@foreach($journal->transactions as $t)
@if($journal->transactiontype->type == 'Withdrawal' && $t->amount < 0)
{{mf($t->amount)}}
@endif
@if($journal->transactiontype->type == 'Deposit' && $t->amount > 0)
{{mf($t->amount)}}
@endif
@if($journal->transactiontype->type == 'Transfer' && $t->amount > 0)
{{mf($t->amount)}}
@endif
@endforeach
</span>
</a>
@endforeach
</div>