Skip to content

Firefly III: a personal finances manager

partly add

Sander Dorigo6e35db820b82
diff --git a/resources/views/budgets/partials/unused-amount-left.twig b/resources/views/budgets/partials/unused-amount-left.twig
deleted file mode 100644
index 59a8d8914f..0000000000
--- a/resources/views/budgets/partials/unused-amount-left.twig
+++ /dev/null
@@ -1,96 +0,0 @@
-{{-- The amount left can only be shown for actual budget limits. --}}
-{% for budgetLimit in budget.budgeted %}
- <span class="left_span" data-currency="{{ budgetLimit.currency_id }}" data-limit="{{ budgetLimit.id }}" data-value="{{ budgetLimit.left }}" class="amount_left">
- {{-- the amount left --}}
- <span title="{{ 'left_in_budget_limit_overview'|_ }}">{{ format_amount_by_symbol(budgetLimit.left, budgetLimit.currency_symbol, budgetLimit.currency_decimal_places) }}</span>
-
- {{-- if the budget limit is in the past, this is not interesting. --}}
- {{-- if there is nothing left, this is not interesting. --}}
- {% if not budgetLimit.in_past and -1 == bccomp('0',budgetLimit.left) %}
- {% if 0 == budgetLimit.active_days_left %}
- <span title="{{ trans('firefly.left_in_budget_limit_per_day', {days: 0}) }}">({{ format_amount_by_symbol(budgetLimit.left, budgetLimit.currency_symbol, budgetLimit.currency_decimal_places) }})
- @else
- <span title="{{ trans('firefly.left_in_budget_limit_per_day', {days: budgetLimit.active_days_left}) }}">({{ format_amount_by_symbol(budgetLimit.left / budgetLimit.active_days_left, budgetLimit.currency_symbol, budgetLimit.currency_decimal_places) }})</span>
- @endif
- @endif
-
- {{-- if there is nothing left, just format 0.00 --}}
- {% if not budgetLimit.in_past and -1 != bccomp('0',budgetLimit.left) %}
- <span title="{{ 'nothing_left_in_budget'|_ }}">({{ format_amount_by_symbol('0', budgetLimit.currency_symbol, budgetLimit.currency_decimal_places) }})</span>
- @endif
-</span><br />
-@endforeach
-
-
-{{--
-{% for spentInfo in budget.spent %}
- {% set countLimit = 0 %}
- <!-- loop each budget limit collected for this budget in this period. -->
- {% for budgetLimit in budget.budgeted %}
- <!-- now looping a single budget limit. -->
- {% if spentInfo.currency_id == budgetLimit.currency_id and budgetLimit.in_range %}
- <!-- the code below is used for budget limits INSIDE the current view range. -->
- {% set countLimit = countLimit + 1 %}
-
- <span class="left_span" data-currency="{{ spentInfo.currency_id }}" data-limit="{{ budgetLimit.id }}"
- data-value="{{ spentInfo.spent + budgetLimit.amount }}" class="amount_left">
- <!--the amount left is automatically calculated. -->
- {{ format_amount_by_symbol(spentInfo.spent + budgetLimit.amount, spentInfo.currency_symbol, spentInfo.currency_decimal_places) }}
- {% if spentInfo.spent + budgetLimit.amount > 0 %}
- {% if 0 == activeDaysLeft %}
- ({{ format_amount_by_symbol(spentInfo.spent + budgetLimit.amount, spentInfo.currency_symbol, spentInfo.currency_decimal_places) }})
- @else
- ({{ format_amount_by_symbol((spentInfo.spent + budgetLimit.amount) / activeDaysLeft, spentInfo.currency_symbol, spentInfo.currency_decimal_places) }})
- @endif
- @else
- ({{ format_amount_by_symbol(0, spentInfo.currency_symbol, spentInfo.currency_decimal_places) }})
- @endif
- </span>
- <br/>
- @endif
-
- {% if spentInfo.currency_id == budgetLimit.currency_id and not budgetLimit.in_range and 0.0 == budgetLimit.total_days %}
- <span class="left_span" data-currency="{{ spentInfo.currency_id }}" data-limit="{{ budgetLimit.id }}"
- data-value="{{ spentInfo.spent + budgetLimit.amount }}" class="amount_left">
- {{ format_amount_by_symbol(spentInfo.spent + budgetLimit.amount, spentInfo.currency_symbol, spentInfo.currency_decimal_places) }}
- </span>
- <span class="text-muted">({{ 'unknown'|_ }})</span>
- @endif
- {% if spentInfo.currency_id == budgetLimit.currency_id and not budgetLimit.in_range and 0.0 != budgetLimit.total_days %}
-
- <span class="left_span" data-currency="{{ spentInfo.currency_id }}" data-limit="{{ budgetLimit.id }}"
- data-value="{{ spentInfo.spent + budgetLimit.amount }}" class="amount_left">
- {{ format_amount_by_symbol(spentInfo.spent + budgetLimit.amount, spentInfo.currency_symbol, spentInfo.currency_decimal_places) }}
- </span>
- ({{ format_amount_by_symbol((spentInfo.spent + budgetLimit.amount) / budgetLimit.total_days, spentInfo.currency_symbol, spentInfo.currency_decimal_places) }})
- @endif
-
- @endforeach
-
- {% if countLimit == 0 %}
- <!-- display nothing -->
- @endif
- -->
-@endforeach
- {% for budgetLimit in budget.budgeted %}
- {% if null == budget.spent[budgetLimit.currency_id] %}
- <span class="left_span" data-currency="{{ spentInfo.currency_id }}" data-limit="{{ budgetLimit.id }}"
- data-value="{{ spentInfo.spent + budgetLimit.amount }}" class="amount_left">
- {{ format_amount_by_symbol(budgetLimit.amount, budgetLimit.currency_symbol, budgetLimit.currency_decimal_places) }}
- {% if budgetLimit.in_range %}
- {% if 0 == activeDaysLeft %}
- ({{ format_amount_by_symbol(budgetLimit.amount, budgetLimit.currency_symbol, budgetLimit.currency_decimal_places) }})
- @else
- ({{ format_amount_by_symbol(budgetLimit.amount / activeDaysLeft, budgetLimit.currency_symbol, budgetLimit.currency_decimal_places) }})
- @endif
- @endif
- {% if not budgetLimit.in_range %}
- <!-- For issue #10441, add per day if the budget limit is out of range. -->
- ({{ format_amount_by_symbol(budgetLimit.amount / budgetLimit.total_days, budgetLimit.currency_symbol, budgetLimit.currency_decimal_places) }})
- @endif
- </span>
- <br/>
- @endif
-
-@endforeach
---}}
diff --git a/resources/views/budgets/partials/unused-amount-spent.twig b/resources/views/budgets/partials/unused-amount-spent.twig
deleted file mode 100644
index 8fdf735927..0000000000
--- a/resources/views/budgets/partials/unused-amount-spent.twig
+++ /dev/null
@@ -1,42 +0,0 @@
-{{-- this is spent in budget limits: --}}
-{% for budgetLimit in budget.budgeted %}
- <span title="{{ 'spent_this_period'|_ }}">{{ format_amount_by_symbol(budgetLimit.spent, budgetLimit.currency_symbol, budgetLimit.currency_decimal_places) }}</span>
- {% if 0 == budgetLimit.active_days_passed %}
- <span title="{{ trans('firefly.spent_this_period_per_day', {days: 0}) }}">({{ format_amount_by_symbol(budgetLimit.spent, budgetLimit.currency_symbol, budgetLimit.currency_decimal_places) }})</span>
- @else
- <span title="{{ trans('firefly.spent_this_period_per_day', {days: budgetLimit.active_days_passed}) }}">({{ format_amount_by_symbol(budgetLimit.spent / budgetLimit.active_days_passed, budgetLimit.currency_symbol, budgetLimit.currency_decimal_places) }})</span>
- @endif
-<br />
-@endforeach
-
-{{-- this is spent NOT in budget limits: --}}
-{% for spent in budget.spent %}
- {% if 0 != bccomp('0', spent.spent_outside) %}
- <span title="{{ 'spent_in_budget_limit_outside_period'|_ }}">{{ format_amount_by_symbol(spent.spent_outside, spent.currency_symbol, spent.currency_decimal_places) }}</span>
- {% if 0 == activeDaysPassed %}
- <span title="{{ trans('firefly.spent_in_budget_limit_outside_period_per_day', {days: 0}) }}">({{ format_amount_by_symbol(spent.spent_outside, spent.currency_symbol, spent.currency_decimal_places) }})</span>
- @else
- <span title="{{ trans('firefly.spent_in_budget_limit_outside_period_per_day', {days: activeDaysPassed}) }}">({{ format_amount_by_symbol(spent.spent_outside / activeDaysPassed, spent.currency_symbol, spent.currency_decimal_places) }})</span>
- @endif
- <br />
- @endif
-@endforeach
-
-{{--
-
-
-{% for spentInfo in budget.spent %}
- {{ format_amount_by_symbol(spentInfo.spent, spentInfo.currency_symbol, spentInfo.currency_decimal_places) }}
- {% if 0 == activeDaysPassed %}
- ({{ format_amount_by_symbol(spentInfo.spent, spentInfo.currency_symbol, spentInfo.currency_decimal_places) }})
- @else
- ({{ format_amount_by_symbol(spentInfo.spent / activeDaysPassed, spentInfo.currency_symbol, spentInfo.currency_decimal_places) }})
- @endif
- <br/>
-@endforeach
-{% for budgetLimit in budget.budgeted %}
- {% if null == budget.spent[budgetLimit.currency_id] %}
- {{ format_amount_by_symbol(0, budgetLimit.currency_symbol, budgetLimit.currency_decimal_places) }}<br/>
- @endif
-@endforeach
---}}
diff --git a/resources/views/categories/create.twig b/resources/views/categories/create.blade.php
similarity index 85%
rename from resources/views/categories/create.twig
rename to resources/views/categories/create.blade.php
index 4cd32c906e..953e7e5618 100644
--- a/resources/views/categories/create.twig
+++ b/resources/views/categories/create.blade.php
@@ -1,11 +1,5 @@
@extends('layout.v3.session')
-
-
- {{ Breadcrumbs.render(Route.getCurrentRoute.getName) }}
-@endsection
-
@section('content')
-
<form method="POST" action="{{ route('categories.store') }}" accept-charset="UTF-8" class="form-horizontal" id="store" enctype="multipart/form-data">
<input name="_token" type="hidden" value="{{ csrf_token() }}">
<div class="row">
@@ -15,7 +9,7 @@
<h3 class="card-title">{{ __('firefly.mandatoryFields') }}</h3>
</div>
<div class="card-body">
- {!! ExpandedForm::text('name') }}
+ {!! ExpandedForm::text('name') !!}
</div>
</div>
</div>
@@ -26,8 +20,8 @@
<h3 class="card-title">{{ __('firefly.optionalFields') }}</h3>
</div>
<div class="card-body">
- {!! ExpandedForm::textarea('notes', null, {helpText: trans('firefly.field_supports_markdown')} ) }}
- {!! ExpandedForm::file('attachments[]', {'multiple': 'multiple','helpText': trans('firefly.upload_max_file_size', {'size': uploadSize|filesize}) }) }}
+ {!! ExpandedForm::textarea('notes', null, ['helpText' => trans('firefly.field_supports_markdown')] ) !!}
+ {!! ExpandedForm::file('attachments[]', ['multiple' => 'multiple','helpText' => trans('firefly.upload_max_file_size', ['size' => print_nice_filesize($uploadSize)])]) !!}
</div>
</div>
</div>
@@ -40,11 +34,11 @@
<h3 class="card-title">{{ __('firefly.options') }}</h3>
</div>
<div class="card-body">
- {!! ExpandedForm::optionsList('create','category') }}
+ {!! ExpandedForm::optionsList('create','category') !!}
</div>
<div class="card-footer">
<button type="submit" class="btn text-end btn-success">
- {{ 'store_category'|_ }}
+ {{ __('firefly.store_category') }}
</button>
</div>
</div>
@@ -53,5 +47,6 @@
</form>
@endsection
@section('scripts')
+ @vite(['js/pages/generic.js'])
<script type="text/javascript" src="v1/js/ff/budgets/create.js?v={{ $FF_BUILD_TIME }}" nonce="{{ $JS_NONCE }}"></script>
@endsection
diff --git a/resources/views/categories/delete.twig b/resources/views/categories/delete.blade.php
similarity index 66%
rename from resources/views/categories/delete.twig
rename to resources/views/categories/delete.blade.php
index 73045d344f..53c740add9 100644
--- a/resources/views/categories/delete.twig
+++ b/resources/views/categories/delete.blade.php
@@ -1,18 +1,13 @@
@extends('layout.v3.session')
-
-
- {{ Breadcrumbs.render(Route.getCurrentRoute.getName, category) }}
-@endsection
-
@section('content')
- <form method="POST" action="{{ route('categories.destroy',category.id) }}" accept-charset="UTF-8" class="form-horizontal" id="destroy">
+ <form method="POST" action="{{ route('categories.destroy',$category->id) }}" accept-charset="UTF-8" class="form-horizontal" id="destroy">
<input name="_token" type="hidden" value="{{ csrf_token() }}">
<div class="row">
<div class="col-lg-6 offset-lg-3 col-md-12 col-sm-12">
<div class="card card-danger card-outline">
<div class="card-header">
- <h3 class="card-title">{{ trans('form.delete_category', {'name': category.name}) }}</h3>
+ <h3 class="card-title">{{ trans('form.delete_category', ['name' => $category->name]) }}</h3>
</div>
<div class="card-body">
<p class="text-danger">
@@ -20,17 +15,17 @@
</p>
<p>
- {{ trans('form.category_areYouSure', {'name': category.name}) }}
+ {{ trans('form.category_areYouSure', ['name' => $category->name]) }}
</p>
<p>
- {% if category.transactionjournals.count() > 0 %}
- {{ Lang::choice('form.category_keep_transactions', category.transactionjournals.count(), {count: category.transactionjournals.count() }) }}
+ @if($category->transactionjournals->count())
+ {{ Lang::choice('form.category_keep_transactions', $category->transactionjournals->count(), ['count' => $category->transactionjournals->count()]) }}
@endif
</p>
</div>
- <div class="card-footer">
- <input type="submit" name="submit" value="{{ trans('form.deletePermanently') }}" class="btn btn-danger text-end"/>
+ <div class="card-footer text-end">
+ <input type="submit" name="submit" value="{{ trans('form.deletePermanently') }}" class="btn btn-danger"/>
<a href="{{ URL::previous() }}" class="btn-outline-secondary btn">{{ trans('form.cancel') }}</a>
</div>
</div>
diff --git a/resources/views/categories/edit.twig b/resources/views/categories/edit.blade.php
similarity index 75%
rename from resources/views/categories/edit.twig
rename to resources/views/categories/edit.blade.php
index c160f53c99..1a3c5ea818 100644
--- a/resources/views/categories/edit.twig
+++ b/resources/views/categories/edit.blade.php
@@ -1,17 +1,12 @@
@extends('layout.v3.session')
-
-
- {{ Breadcrumbs.render(Route.getCurrentRoute.getName, category) }}
-@endsection
-
@section('content')
- <form method="post" action="{{ route('categories.update',category.id) }}" class="form-horizontal"
+ <form method="post" action="{{ route('categories.update',$category->id) }}" class="form-horizontal"
accept-charset="UTF-8"
enctype="multipart/form-data">
<input type="hidden" name="_token" value="{{ csrf_token() }}"/>
- <input type="hidden" name="id" value="{{ category.id }}"/>
+ <input type="hidden" name="id" value="{{ $category->id }}"/>
<div class="row">
<div class="col-lg-6 col-md-6 col-sm-12">
<div class="card">
@@ -19,7 +14,7 @@
<h3 class="card-title">{{ __('firefly.mandatoryFields') }}</h3>
</div>
<div class="card-body">
- {!! ExpandedForm::text('name', category.name) }}
+ {!! ExpandedForm::text('name', $category->name) !!}
</div>
</div>
</div>
@@ -30,8 +25,8 @@
<h3 class="card-title">{{ __('firefly.optionalFields') }}</h3>
</div>
<div class="card-body">
- {!! ExpandedForm::textarea('notes', preFilled.notes, {helpText: trans('firefly.field_supports_markdown')} ) }}
- {!! ExpandedForm::file('attachments[]', {'multiple': 'multiple','helpText': trans('firefly.upload_max_file_size', {'size': uploadSize|filesize}) }) }}
+ {!! ExpandedForm::textarea('notes', $preFilled['notes'], ['helpText' => trans('firefly.field_supports_markdown')] ) !!}
+ {!! ExpandedForm::file('attachments[]', ['multiple' => 'multiple','helpText' => trans('firefly.upload_max_file_size', ['size' => print_nice_filesize($uploadSize)])]) !!}
</div>
</div>
</div>
@@ -46,11 +41,11 @@
<h3 class="card-title">{{ __('firefly.options') }}</h3>
</div>
<div class="card-body">
- {!! ExpandedForm::optionsList('update','category') }}
+ {!! ExpandedForm::optionsList('update','category') !!}
</div>
<div class="card-footer">
<button type="submit" class="btn text-end btn-success">
- {{ 'update_category'|_ }}
+ {{ __('firefly.update_category') }}
</button>
</div>
</div>
diff --git a/resources/views/categories/no-category.twig b/resources/views/categories/no-category.blade.php
similarity index 83%
rename from resources/views/categories/no-category.twig
rename to resources/views/categories/no-category.blade.php
index 0d8f65286d..91871cdf86 100644
--- a/resources/views/categories/no-category.twig
+++ b/resources/views/categories/no-category.blade.php
@@ -1,22 +1,17 @@
@extends('layout.v3.session')
-
-
- {{ Breadcrumbs.render(Route.getCurrentRoute.getName, start, end) }}
-@endsection
-
@section('content')
{{-- upper show-all instruction --}}
@if(count($periods) > 0)
<div class="row">
- <div class="col-lg-offset-10 col-lg-2 offset-md-9 col-md-3 col-sm-12 col-xs-12">
+ <div class="offset-lg-10 col-lg-2 offset-md-9 col-md-3 col-sm-12 col-xs-12">
<p class="small text-center"><a href="{{ route('categories.no-category.all') }}">{{ __('firefly.showEverything') }}</a></p>
</div>
</div>
@endif
<div class="row">
- <div class="@if(count($periods) > 0)col-lg-10 col-md-9 col-sm-12 col-xs-12@elsecol-lg-12 col-md-12 col-sm-12 col-xs-12@endif">
+ <div class="@if(count($periods) > 0) col-lg-10 col-md-9 col-sm-12 col-xs-12 @else col-lg-12 col-md-12 col-sm-12 col-xs-12 @endif">
<div class="card">
<div class="card-header">
<h3 class="card-title">{{ $subTitle }}</h3>
@@ -51,7 +46,7 @@
{{-- lower show-all instruction --}}
@if(count($periods) > 0)
<div class="row">
- <div class="col-lg-offset-10 col-lg-2 offset-md-9 col-md-3 col-sm-12 col-xs-12">
+ <div class="offset-lg-10 col-lg-2 offset-md-9 col-md-3 col-sm-12 col-xs-12">
<p class="small text-center"><a href="{{ route('categories.no-category',['all']) }}">{{ __('firefly.showEverything') }}</a></p>
</div>
</div>
@@ -59,6 +54,7 @@
@endsection
@section('scripts')
+ @vite(['js/pages/generic.js'])
{{-- required for groups.twig --}}
<script type="text/javascript" src="v1/js/ff/list/groups.js?v={{ $FF_BUILD_TIME }}" nonce="{{ $JS_NONCE }}"></script>
@endsection
diff --git a/resources/views/categories/show.twig b/resources/views/categories/show.blade.php
similarity index 72%
rename from resources/views/categories/show.twig
rename to resources/views/categories/show.blade.php
index f6390d6d26..93ecfbb5dc 100644
--- a/resources/views/categories/show.twig
+++ b/resources/views/categories/show.blade.php
@@ -1,18 +1,13 @@
@extends('layout.v3.session')
-
-
- {{ Breadcrumbs.render(Route.getCurrentRoute.getName, category, start, end) }}
-@endsection
-
@section('content')
<div class="row">
- {% if Route.getCurrentRoute.getName == 'categories.show' %}
+ @if(Route::getCurrentRoute()->getName() == 'categories.show')
{{-- both charts --}}
- <div class="{% if attachments.count() == 0 %}col-lg-6 col-md-12 col-sm-12 col-xs-12@elsecol-lg-4 col-md-12 col-sm-12 col-xs-12@endif">
- <div class="card">
+ <div class="@if($attachments->count() == 0) col-lg-6 col-md-12 col-sm-12 col-xs-12 @else col-lg-4 col-md-12 col-sm-12 col-xs-12 @endif ">
+ <div class="card mb-2">
<div class="card-header">
<h3 class="card-title">
- {{ trans('firefly.chart_category_in_period', {name: category.name, start: $start->isoFormat($monthAndDayFormat), end: $end->isoFormat($monthAndDayFormat) }) }}
+ {{ trans('firefly.chart_category_in_period', ['name' => $category->name, 'start' => $start->isoFormat($monthAndDayFormat), 'end' => $end->isoFormat($monthAndDayFormat)]) }}
</h3>
</div>
<div class="card-body">
@@ -20,11 +15,11 @@
</div>
</div>
</div>
- <div class="{% if attachments.count() == 0 %}col-lg-6 col-md-12 col-sm-12 col-xs-12@elsecol-lg-4 col-md-12 col-sm-12 col-xs-12@endif">
- <div class="card">
+ <div class="@if(0 === $attachments->count()) col-lg-6 col-md-12 col-sm-12 col-xs-12 @else col-lg-4 col-md-12 col-sm-12 col-xs-12 @endif ">
+ <div class="card mb-2">
<div class="card-header">
<h3 class="card-title">
- {{ trans('firefly.chart_category_all', {name: category.name }) }}
+ {{ trans('firefly.chart_category_all', ['name' => $category->name]) }}
</h3>
</div>
<div class="card-body">
@@ -33,13 +28,13 @@
</div>
</div>
@endif
- {% if Route.getCurrentRoute.getName == 'categories.show.all' %}
+ @if(Route::getCurrentRoute()->getName() == 'categories.show.all')
{{-- all chart --}}
- <div class="{% if attachments.count() == 0 %}col-lg-12 col-md-12 col-sm-12 col-xs-12@elsecol-lg-8 col-md-12 col-sm-12 col-xs-12@endif">
- <div class="card">
+ <div class="@if(0 === $attachments->count()) col-lg-12 col-md-12 col-sm-12 col-xs-12 @else col-lg-8 col-md-12 col-sm-12 col-xs-12 @endif ">
+ <div class="card mb-2">
<div class="card-header">
<h3 class="card-title">
- {{ trans('firefly.chart_category_all', {name: category.name }) }}
+ {{ trans('firefly.chart_category_all', ['name' => $category->name ]) }}
</h3>
</div>
<div class="card-body">
@@ -50,7 +45,7 @@
@endif
@if($attachments->count() > 0)
<div class="col-lg-4 col-md-12 col-sm-12 col-xs-12">
- <div class="card">
+ <div class="card mb-2">
<div class="card-header">
<h3 class="card-title">
{{ __('firefly.attachments') }}
@@ -65,16 +60,16 @@
</div>
@if(count($periods) > 0)
<div class="row">
- <div class="col-lg-offset-10 col-lg-2 col-md-offset-10 col-md-2 col-sm-12 col-xs-12">
- <p class="small text-center"><a href="{{ route('categories.show.all',[category.id]) }}">{{ __('firefly.showEverything') }}</a></p>
+ <div class="offset-lg-10 offset-lg-10 col-lg-2 offset-md-10 col-md-2 col-sm-12 col-xs-12">
+ <p class="small text-center"><a href="{{ route('categories.show.all',[$category->id]) }}">{{ __('firefly.showEverything') }}</a></p>
</div>
</div>
@endif
<div class="row">
- <div class="@if(count($periods) > 0)col-lg-10 col-md-8 col-sm-12 col-xs-12@elsecol-lg-12 col-md-12 col-sm-12 col-xs-12@endif">
+ <div class="@if(count($periods) > 0)col-lg-10 col-md-8 col-sm-12 col-xs-12 @else col-lg-12 col-md-12 col-sm-12 col-xs-12 @endif ">
- <div class="card">
+ <div class="card mb-2">
<div class="card-header">
<h3 class="card-title">{{ __('firefly.transactions') }}</h3>
</div>
@@ -83,7 +78,7 @@
<x-lists.groups-large :groups="$groups" />
<p>
<span class="bi bi-calendar"></span>
- <a href="{{ route('categories.show.all', [category.id]) }}">
+ <a href="{{ route('categories.show.all', [$category->id]) }}">
{{ __('firefly.show_all_no_filter') }}
</a>
</p>
@@ -91,7 +86,7 @@
<x-lists.groups-large :groups="$groups" />
<p>
<span class="bi bi-calendar"></span>
- <a href="{{ route('categories.show', [category.id]) }}">
+ <a href="{{ route('categories.show', [$category->id]) }}">
{{ __('firefly.show_the_current_period_and_overview') }}
</a>
</p>
@@ -108,10 +103,11 @@
@endsection
@section('scripts')
+ @vite(['js/pages/generic.js'])
<script type="text/javascript" nonce="{{ $JS_NONCE }}">
- var current = '{{ route('chart.category.current', [category.id]) }}';
- var everything = '{{ route('chart.category.all', [category.id]) }}';
- var specific = '{{ route('chart.category.specific', [category.id, $start->format('Ymd')]) }}';
+ var current = '{{ route('chart.category.current', [$category->id]) }}';
+ var everything = '{{ route('chart.category.all', [$category->id]) }}';
+ var specific = '{{ route('chart.category.specific', [$category->id, $start->format('Ymd')]) }}';
</script>
<script type="text/javascript" src="v1/js/lib/Chart.bundle.min.js?v={{ $FF_BUILD_TIME }}" nonce="{{ $JS_NONCE }}"></script>
<script type="text/javascript" src="v1/js/ff/charts.defaults.js?v={{ $FF_BUILD_TIME }}" nonce="{{ $JS_NONCE }}"></script>