mirror of
https://github.com/firefly-iii/firefly-iii.git
synced 2025-02-25 18:45:27 -06:00
Add two new ranges #954
This commit is contained in:
parent
03956af88a
commit
9ece209c72
@ -168,6 +168,16 @@ trait GetConfigurationData
|
||||
$ranges[ucfirst((string)trans('firefly.today'))] = [$todayStart, $todayEnd];
|
||||
}
|
||||
|
||||
// last seven days:
|
||||
$seven = Carbon::create()->subDays(7);
|
||||
$index = (string)trans('firefly.last_seven_days');
|
||||
$ranges[$index] = [$seven, new Carbon];
|
||||
|
||||
// last 30 days:
|
||||
$thirty = Carbon::create()->subDays(30);
|
||||
$index = (string)trans('firefly.last_thirty_days');
|
||||
$ranges[$index] = [$thirty, new Carbon];
|
||||
|
||||
// everything
|
||||
$index = (string)trans('firefly.everything');
|
||||
$ranges[$index] = [$first, new Carbon];
|
||||
@ -259,9 +269,10 @@ trait GetConfigurationData
|
||||
$now = time();
|
||||
if (0 === $lastTime) {
|
||||
request()->session()->flash('info', trans('firefly.recurring_never_cron'));
|
||||
|
||||
return;
|
||||
}
|
||||
if($now - $lastTime > 129600) {
|
||||
if ($now - $lastTime > 129600) {
|
||||
request()->session()->flash('warning', trans('firefly.recurring_cron_long_ago'));
|
||||
}
|
||||
}
|
||||
|
@ -30,6 +30,8 @@ return [
|
||||
'delete' => 'Delete',
|
||||
'split' => 'Split',
|
||||
'clone' => 'Clone',
|
||||
'last_seven_days' => 'Last seven days',
|
||||
'last_thirty_days' => 'Last thirty days',
|
||||
'welcomeBack' => 'What\'s playing?',
|
||||
'everything' => 'Everything',
|
||||
'today' => 'today',
|
||||
|
Loading…
Reference in New Issue
Block a user