Skip to content

Firefly III: a personal finances manager

fix some views

Sander Dorigo722584eacda0
diff --git a/resources/views/attachments/index.blade.php b/resources/views/attachments/index.blade.php
index ea34932634..a36b2cc53a 100644
--- a/resources/views/attachments/index.blade.php
+++ b/resources/views/attachments/index.blade.php
@@ -40,7 +40,7 @@
<td data-value="{{ $att->attachable_type }}_{{ $att->attachable_id }}">
@if($att->attachable_type === 'FireflyIII\\Models\\TransactionJournal')
<a href="{{ route('transactions.show', [$att->attachable_id]) }}">
- {{ $att->attachable->description }}
+ {{ $att->attachable?->description }}
</a>
@else
{{ $att->attachable_type }}
diff --git a/resources/views/budgets/index.blade.php b/resources/views/budgets/index.blade.php
index 79391f9d46..1587bb345f 100644
--- a/resources/views/budgets/index.blade.php
+++ b/resources/views/budgets/index.blade.php
@@ -194,12 +194,12 @@
<table class="table sortable-table table-striped sortable" id="budgetList">
<thead>
<tr>
- <th class="hidden-sm ten">&nbsp;</th>
+ <th class="ten">&nbsp;</th>
<th>{{ __('firefly.budget') }}</th>
<th class="quarter">{{ __('firefly.budgeted') }}</th>
<th>{{ __('firefly.spent') }} ({{ strtolower(__('firefly.per_day')) }})</th>
<th>{{ __('firefly.left') }} ({{ strtolower(__('firefly.per_day')) }})</th>
- <th class="hidden-sm ten">&nbsp;</th>
+ <th class="ten">&nbsp;</th>
</tr>
</thead>
<tbody>
@@ -318,7 +318,7 @@
@endforeach
@endif
</td>
- <td class="hidden-sm spent text-end" data-id="{{ $budget['id'] }}">
+ <td class="spent text-end" data-id="{{ $budget['id'] }}">
{{-- this is spent in budget limits: --}}
@foreach($budget['budgeted'] as $budgetLimit)
<span title="{{ __('firefly.spent_this_period') }}">{!! format_amount_by_symbol($budgetLimit['spent'], $budgetLimit['currency_symbol'], $budgetLimit['currency_decimal_places']) !!}</span>
@@ -367,7 +367,7 @@
</span><br />
@endforeach
</td>
- <td class="hidden-sm text-end">
+ <td class="text-end">
<div class="dropdown">
diff --git a/resources/views/components/lists/accounts.blade.php b/resources/views/components/lists/accounts.blade.php
index 044fdd8bd5..5226ff64fe 100644
--- a/resources/views/components/lists/accounts.blade.php
+++ b/resources/views/components/lists/accounts.blade.php
@@ -133,7 +133,7 @@
@endforeach
</span>
</td>
- <td class="hidden-sm justify-content-end">
+ <td class="justify-content-end">
<div class="dropdown">
<button class="btn btn-outline-secondary btn-sm dropdown-toggle" type="button" id="action_menu_{{$account->id}}" data-bs-toggle="dropdown" aria-expanded="false">
{{ __('firefly.actions') }}
diff --git a/resources/views/components/lists/piggy-banks.blade.php b/resources/views/components/lists/piggy-banks.blade.php
index 7c673b38f7..2ec361755f 100644
--- a/resources/views/components/lists/piggy-banks.blade.php
+++ b/resources/views/components/lists/piggy-banks.blade.php
@@ -6,21 +6,19 @@
<x-elements.card-header-with-menu :cardTitle="$objectGroup['object_group_title']" :route="route('piggy-banks.create')" :linkTitle="__('firefly.create_new_piggy_bank')" />
<div class="card-body p-0">
-<table class="table table-hover table-sm table-sm piggy-sortable">
+<table class="table table-bordered table-hover table-sm table-sm piggy-sortable">
<thead>
<tr>
- <th class="w-4 d-none d-md-table-cell">&nbsp;</th>
- <!--
- <th class="w-4"></th> {{-- mobile handlers --}}
- -->
+ <th class="w-4">&nbsp;</th>
+ <th class="w-4 d-lg-none"></th> {{-- mobile handlers --}}
<th class="w-25" style="width:30%;">{{ __('firefly.piggy_bank') }}</th>
<th class="w-10 text-end">{{ __('firefly.saved_so_far') }}</th>
- <th class="d-none d-md-table-cell"></th>
- <th class="d-none d-md-table-cell"></th>
- <th class="d-none d-md-table-cell"></th>
+ <th class="d-none d-lg-table-cell"></th>
+ <th class="d-none d-lg-table-cell"></th>
+ <th class="d-none d-lg-table-cell"></th>
<th class="w-10 text-end">{{ __('firefly.target_amount') }}</th>
- <th class="w-10 d-none d-md-table-cell text-end">{{ __('firefly.left_to_save') }}</th>
- <th class="w-15 d-none d-md-table-cell text-end">{{ __('firefly.suggested_savings_per_month') }}</th>
+ <th class="w-10 text-end d-none d-lg-table-cell">{{ __('firefly.left_to_save') }}</th>
+ <th class="w-15 text-end d-none d-xxl-table-cell">{{ __('firefly.suggested_savings_per_month') }}</th>
<th class="w-4">&nbsp;</th>
</tr>
</thead>
@@ -28,18 +26,16 @@
<tbody class="piggy-connected-list" @if(0 !== $objectGroupOrder)data-title="{{ $objectGroup['object_group_title'] }}"@else data-title=""@endif>
@foreach($objectGroup['piggy_banks'] as $piggy)
<tr class="piggy-sortable" data-id="{{ $piggy['id'] }}" data-name="{{ $piggy['name'] }}" data-order="{{ $piggy['order'] }}">
- <td class="d-none d-md-table-cell">
+ <td class="">
<a class="btn btn-sm bi bi-list piggy-handle"></a>
<span class="loadSpin"></span>
</td>
- <!--
- <td class="d-table-cell d-md-none">
+ <td class="d-lg-none"> <!-- mobile buttons -->
<div class="btn-group btn-group-sm">
- <a href="{{ route('piggy-banks.remove-money-mobile', $piggy['id']) }}" class="btn btn-secondary btn-sm"><span class="bi bi-dash"></span></a>
- <a href="{{ route('piggy-banks.add-money-mobile', $piggy['id']) }}" class="btn btn-secondary btn-sm"><span class="bi bi-plus"></span></a>
+ <a href="{{ route('piggy-banks.remove-money-mobile', $piggy['id']) }}" class="btn btn-outline-danger btn-sm"><span class="bi bi-dash"></span></a>
+ <a href="{{ route('piggy-banks.add-money-mobile', $piggy['id']) }}" class="btn btn-outline-success btn-sm"><span class="bi bi-plus"></span></a>
</div>
</td>
- -->
<td>
<a href="{{ route('piggy-banks.show', $piggy['id']) }}" title="{{ $piggy['name'] }}">{{ $piggy['name'] }}</a>
@if(count($piggy['attachments']) > 0)
@@ -54,14 +50,14 @@
@endif
</span>
</td>
- <td class="d-none d-md-table-cell" style="width:40px;">
+ <td class="d-none d-lg-table-cell" style="width:40px;">
@if($piggy['current_amount'] > 0)
<a href="{{ route('piggy-banks.remove-money', $piggy['id']) }}" class="btn btn-secondary btn-sm removeMoney" data-id="{{ $piggy['id'] }}">
<span data-id="{{ $piggy['id'] }}" class="bi bi-dash"></span></a>
@endif
</td>
- <td class="piggyBar d-none d-md-table-cell">
+ <td class="d-none d-lg-table-cell piggyBar">
@if(null !== $piggy['percentage'])
<div class="progress"
style="height: 21px" role="progressbar" aria-valuenow="{{ round(max(30, $piggy['percentage'])) }}" aria-valuemin="0" aria-valuemax="100">
@@ -82,7 +78,7 @@
</td>
- <td style="width:40px;" class="d-none d-md-table-cell">
+ <td class="d-none d-lg-table-cell">
@if($piggy['left_to_save'] > 0 || null === $piggy['left_to_save'])
<a href="{{ route('piggy-banks.add-money', $piggy['id']) }}" class="btn btn-secondary btn-sm addMoney" data-id="{{ $piggy['id'] }}">
<span data-id="{{ $piggy['id'] }}" class="b bi-plus"></span></a>
@@ -96,7 +92,7 @@
@endif
@endif
</td>
- <td class="text-end d-none d-md-table-cell">
+ <td class="text-end d-none d-lg-table-cell">
@if($piggy['left_to_save'] > 0)
<span title="{{ __('firefly.left_to_save') }}">{!! format_amount_by_symbol($piggy['left_to_save'],$piggy['currency_symbol'],$piggy['currency_decimal_places']) !!}</span>
@if($convertToPrimary && $piggy['currency_id'] !== $primaryCurrency->id && null !== $piggy['pc_left_to_save'])
@@ -104,7 +100,7 @@
@endif
@endif
</td>
- <td class="d-none d-md-table-cell text-end">
+ <td class="text-end d-none d-xxl-table-cell">
@if(null !== $piggy['target_date'] && null !== $piggy['save_per_month'])
{!! format_amount_by_symbol($piggy['save_per_month'], $piggy['currency_symbol'], $piggy['currency_decimal_places']) !!}
@if($convertToPrimary && $piggy['currency_id'] !== $primaryCurrency->id && null !== $piggy['pc_save_per_month'])
@@ -112,7 +108,7 @@
@endif
@endif
</td>
- <td style="width:100px;" class="text-end">
+ <td class="text-end">
<div class="dropdown">
<button class="btn btn-sm btn-outline-secondary dropdown-toggle" type="button" data-bs-toggle="dropdown" aria-expanded="false">
{{__('firefly.actions')}}
@@ -126,30 +122,29 @@
</tr>
@endforeach
<tr>
- <td class="d-none d-md-table-cell">&nbsp;</td> {{-- handle --}}
- <!--
- <td class="d-table-cell d-md-none">&nbsp;</td> {{-- mobile buttons --}}
- -->
+ <td class="">&nbsp;</td> {{-- handle --}}
+ <td class="d-lg-none ">&nbsp;</td> {{-- mobile buttons --}}
<td>&nbsp;</td> {{-- title --}}
<td class="text-end">
@foreach($objectGroup['sums'] as $sum)
{!! format_amount_by_symbol($sum['saved'], $sum['currency_symbol'], $sum['currency_decimal_places']) !!}<br />
@endforeach
</td>
- <td class="d-none d-md-table-cell">&nbsp;</td> {{-- remove money --}}
- <td class="d-none d-md-table-cell">&nbsp;</td> {{-- progress --}}
- <td class="d-none d-md-table-cell">&nbsp;</td> {{-- add money --}}
+ <td class="d-none d-lg-table-cell">&nbsp;</td> {{-- remove money --}}
+ <td class="d-none d-lg-table-cell">&nbsp;</td> {{-- progress --}}
+ <td class="d-none d-lg-table-cell">&nbsp;</td> {{-- add money --}}
<td class="text-end">
+
@foreach($objectGroup['sums'] as $sum)
{!! format_amount_by_symbol($sum['target'], $sum['currency_symbol'], $sum['currency_decimal_places']) !!}<br />
@endforeach
</td>
- <td class="text-end d-none d-md-table-cell">
+ <td class="text-end d-none d-lg-table-cell">
@foreach($objectGroup['sums'] as $sum)
{!! format_amount_by_symbol($sum['left_to_save'], $sum['currency_symbol'], $sum['currency_decimal_places']) !!}<br />
@endforeach
</td>
- <td class="d-none d-md-table-cell text-end">
+ <td class="text-end d-none d-xxl-table-cell">
@foreach($objectGroup['sums'] as $sum)
{!! format_amount_by_symbol($sum['save_per_month'], $sum['currency_symbol'], $sum['currency_decimal_places']) !!}<br />
@endforeach
diff --git a/resources/views/components/lists/subscriptions.blade.php b/resources/views/components/lists/subscriptions.blade.php
index f0cdf1fc64..6680a80a69 100644
--- a/resources/views/components/lists/subscriptions.blade.php
+++ b/resources/views/components/lists/subscriptions.blade.php
@@ -12,11 +12,11 @@
<tr>
<th class="w-5">&nbsp;</th>
<th class="w-25">{{ __('list.name') }}</th>
- <th class="w-20">{{ __('list.linked_to_rules') }}</th>
+ <th class="w-20 d-xl-table-cell d-none" {{-- hide on LG and smaller --}}>{{ __('list.linked_to_rules') }}</th>
<th class="w-5 text-end">{{ trans('list.matchingAmount') }}</th>
<th class="w-15">{{ trans('list.paid_current_period') }}</th>
<th class="w-15">{{ trans('list.next_expected_match') }}</th>
- <th>{{ trans('list.repeat_freq') }}</th>
+ <th class="d-xl-table-cell d-none">{{ trans('list.repeat_freq') }}</th>
<th>&nbsp;</th>
</tr>
</thead>
@@ -40,7 +40,7 @@
@endif
</td>
- <td class="hidden-sm rules">
+ <td class="rules d-xl-table-cell d-none" {{-- hide on LG and smaller --}}>
@if(count($entry['rules']) > 0)
<ul class="list-unstyled">
@foreach($entry['rules'] as $rule)
@@ -142,7 +142,7 @@
</td>
<td class="expected_in_period text-muted">~</td>
@endif
- <td>
+ <td class="d-xl-table-cell d-none">
{{ __('firefly.repeat_freq_' . $entry['repeat_freq']) }}
@if($entry['skip'] > 0)
{{ __('firefly.skips_over') }} {{ $entry['skip'] }}
@@ -166,7 +166,7 @@
@endif
@endif
</td>
- <td class="hidden-sm text-end">
+ <td class="text-end">
<div class="dropdown">
<button class="btn btn-sm btn-outline-secondary dropdown-toggle" type="button" data-bs-toggle="dropdown" aria-expanded="false">
{{ __('firefly.actions') }}
@@ -182,8 +182,8 @@
@if(array_key_exists($objectGroupOrder, $sums))
@foreach($sums[$objectGroupOrder] as $sum)
@if('0' !== $sum['avg'])
- <tr>
- <td>&nbsp;</td> <!-- handle -->
+ <tr {{-- hide on MD and smaller --}} class="d-lg-table-row d-none">
+ <td class="d-xl-table-cell d-none">&nbsp;</td> <!-- handle -->
<td colspan="2" class="text-end"> <!-- title -->
<small>{{ __('firefly.sum') }} ({{ $sum['currency_name'] }})
({{ __('firefly.active_exp_bills_only') }})</small>
@@ -195,8 +195,8 @@
</tr>
@endif
@if('0' !== $sum['total_left_to_pay'])
- <tr>
- <td>&nbsp;</td> <!-- handle -->
+ <tr {{-- hide on MD and smaller --}} class="d-lg-table-row d-none">
+ <td class="d-xl-table-cell d-none">&nbsp;</td> <!-- handle -->
<td colspan="2" class="text-end"> <!-- title -->
<small>{{ __('firefly.sum') }} ({{ $sum['currency_name'] }})
({{ __('firefly.left_to_pay_active_bills') }})</small>
@@ -208,8 +208,8 @@
</tr>
@endif
@if('0' !== $sum['per_period'])
- <tr>
- <td>&nbsp;</td> <!-- handle -->
+ <tr {{-- hide on MD and smaller --}} class="d-lg-table-row d-none">
+ <td class="d-xl-table-cell d-none">&nbsp;</td> <!-- handle -->
<td colspan="2" class="text-end"> <!-- title -->
<small>{{ __('firefly.per_period_sum_' . $sum['period']) }}
({{ $sum['currency_name'] }})
diff --git a/resources/views/recurring/index.blade.php b/resources/views/recurring/index.blade.php
index 9a435da2c3..45fc6975cb 100644
--- a/resources/views/recurring/index.blade.php
+++ b/resources/views/recurring/index.blade.php
@@ -111,7 +111,7 @@
@endforeach
</ul>
</td>
- <td class="hidden-sm text-end">
+ <td class="text-end">
<div class="dropdown">
<button class="btn btn-sm btn-outline-secondary dropdown-toggle" type="button" data-bs-toggle="dropdown" aria-expanded="false">
{{ __('firefly.actions') }}
diff --git a/resources/views/webhooks/index.blade.php b/resources/views/webhooks/index.blade.php
index 7c1386bdf2..881ef018f6 100644
--- a/resources/views/webhooks/index.blade.php
+++ b/resources/views/webhooks/index.blade.php
@@ -86,7 +86,7 @@
<code :title="webhook.full_url" x-text="webhook.url"></code>
</td>
- <td class="hidden-sm text-end">
+ <td class="text-end">
<div class="dropdown">
<button class="btn btn-sm btn-secondary-outline dropdown-toggle" type="button" :id="'webhook_menu_' + webhook.id" data-bs-toggle="dropdown" aria-expanded="false">
{{ __('firefly.actions') }}