From e80481f86076cadaa3835aba6b7c56328fd4f953 Mon Sep 17 00:00:00 2001 From: Lukas Halbritter Date: Mon, 1 Oct 2018 17:20:19 +0200 Subject: [PATCH] The views bookings.index and people.show now use the formatDate and formatAmount helpers. --- resources/views/bookings/index.blade.php | 18 +++++++++--------- resources/views/people/show.blade.php | 21 +++++++++++---------- 2 files changed, 20 insertions(+), 19 deletions(-) diff --git a/resources/views/bookings/index.blade.php b/resources/views/bookings/index.blade.php index 39a05a2..9230bdc 100644 --- a/resources/views/bookings/index.blade.php +++ b/resources/views/bookings/index.blade.php @@ -33,7 +33,7 @@ Saldo - {{ formatAmount($sums[$month - 1]['balance']) }} + {!! formatAmount($sums[$month - 1]['balance']) !!} @@ -45,17 +45,17 @@ @endif {{ $booking->id }} - {{ $booking->date }} + {{ formatDate($booking->date) }} {{ $booking->reference }} {{ $booking->person_or_company }} @if ($booking->signedAmount() < 0) - {{ formatAmount($booking->signedAmount()) }} + {!! formatAmount($booking->signedAmount()) !!} @endif @if ($booking->signedAmount() >= 0) - {{ formatAmount($booking->signedAmount()) }} + {!! formatAmount($booking->signedAmount()) !!} @endif @@ -80,12 +80,12 @@ @if ($subBooking->signedAmount() < 0) - {{ formatAmount($subBooking->signedAmount()) }} + {!! formatAmount($subBooking->signedAmount()) !!} @endif @if ($subBooking->signedAmount() >= 0) - {{ formatAmount($subBooking->signedAmount()) }} + {!! formatAmount($subBooking->signedAmount()) !!} @endif @@ -107,8 +107,8 @@ Monatsabschluss - {{ formatAmount($sums[$month]['expeditures']) }} - {{ formatAmount($sums[$month]['incomes']) }} + {!! formatAmount($sums[$month]['expeditures']) !!} + {!! formatAmount($sums[$month]['incomes']) !!} @@ -120,7 +120,7 @@ Saldo - {{ formatAmount($sums[$month]['balance']) }} + {!! formatAmount($sums[$month]['balance']) !!} diff --git a/resources/views/people/show.blade.php b/resources/views/people/show.blade.php index d8024f1..abcd3ad 100644 --- a/resources/views/people/show.blade.php +++ b/resources/views/people/show.blade.php @@ -55,7 +55,7 @@ Geburtstag - {{ $person->date_of_birth }} + {{ formatDate($person->date_of_birth) }} @@ -70,8 +70,8 @@ @foreach ($person->memberStates as $memberState) - {{ $memberState->joining_date }} - {{ $memberState->leaving_date }} + {{ formatDate($memberState->joining_date) }} + {{ formatDate($memberState->leaving_date) }} @endforeach @@ -80,7 +80,8 @@

{{ $person->fullName() }} ist aktives Mitglied.

@endif -

Gesamtmitgliedszeit: {{ formatAmount($person->activeTime()) }} Jahre.

+

Gesamtmitgliedszeit: {{ formatAmount($person->activeTime(), + false, true) }} Jahre.

@else

{{ $person->fullName() }} war nie Mitglied.

@endif @@ -99,19 +100,19 @@ @foreach ($person->targets as $target) > - {{ $target->date }} + {{ formatDate($target->date) }} {{ $target->reference }} - {{ formatAmount($target->signedAmount()) }} - {{ formatAmount($target->actualsSum()) }} - {{ formatAmount($target->difference()) }} + {!! formatAmount($target->signedAmount()) !!} + {!! formatAmount($target->actualsSum()) !!} + {!! formatAmount($target->difference()) !!} @foreach ($target->actuals as $actual) - {{ $actual->date() }} + {{ formatDate($actual->date()) }} {{ $actual->reference }} - {{ formatAmount($actual->signedAmount()) }} + {!! formatAmount($actual->signedAmount()) !!} @endforeach