mirror of
https://github.com/firefly-iii/firefly-iii.git
synced 2025-10-13 16:00:13 +00:00
Fix #3461
This commit is contained in:
@@ -128,6 +128,10 @@ class SelectController extends Controller
|
|||||||
*/
|
*/
|
||||||
public function selectTransactions(Rule $rule)
|
public function selectTransactions(Rule $rule)
|
||||||
{
|
{
|
||||||
|
if(false===$rule->active) {
|
||||||
|
session()->flash('warning',trans('firefly.cannot_fire_inactive_rules'));
|
||||||
|
return redirect(route('rules.index'));
|
||||||
|
}
|
||||||
// does the user have shared accounts?
|
// does the user have shared accounts?
|
||||||
$first = session('first', Carbon::now()->subYear())->format('Y-m-d');
|
$first = session('first', Carbon::now()->subYear())->format('Y-m-d');
|
||||||
$today = Carbon::now()->format('Y-m-d');
|
$today = Carbon::now()->format('Y-m-d');
|
||||||
|
@@ -298,6 +298,7 @@ return [
|
|||||||
'yearly' => 'yearly',
|
'yearly' => 'yearly',
|
||||||
|
|
||||||
// rules
|
// rules
|
||||||
|
'cannot_fire_inactive_rules' => 'You cannot execute inactive rules.',
|
||||||
'rules' => 'Rules',
|
'rules' => 'Rules',
|
||||||
'rule_name' => 'Name of rule',
|
'rule_name' => 'Name of rule',
|
||||||
'rule_triggers' => 'Rule triggers when',
|
'rule_triggers' => 'Rule triggers when',
|
||||||
|
@@ -107,6 +107,7 @@
|
|||||||
<td>
|
<td>
|
||||||
<div class="btn-group btn-group-xs test_buttons">
|
<div class="btn-group btn-group-xs test_buttons">
|
||||||
{# show which transactions would match #}
|
{# show which transactions would match #}
|
||||||
|
{% if rule.active %}
|
||||||
<a href="#" class="btn btn-default test_rule_triggers" data-id="{{ rule.id }}"
|
<a href="#" class="btn btn-default test_rule_triggers" data-id="{{ rule.id }}"
|
||||||
title="{{ 'test_rule_triggers'|_ }}"><i data-id="{{ rule.id }}"
|
title="{{ 'test_rule_triggers'|_ }}"><i data-id="{{ rule.id }}"
|
||||||
class="test_rule_triggers fa fa-fw fa-flask"></i></a>
|
class="test_rule_triggers fa fa-fw fa-flask"></i></a>
|
||||||
@@ -115,7 +116,7 @@
|
|||||||
<a href="{{ route('rules.select-transactions',rule.id) }}" class="btn btn-default"
|
<a href="{{ route('rules.select-transactions',rule.id) }}" class="btn btn-default"
|
||||||
title=" {{ trans('firefly.apply_rule_selection', {title: rule.title}) }}">
|
title=" {{ trans('firefly.apply_rule_selection', {title: rule.title}) }}">
|
||||||
<i class="fa fa-fw fa-power-off "></i></a>
|
<i class="fa fa-fw fa-power-off "></i></a>
|
||||||
|
{% endif %}
|
||||||
{# duplicate rule #}
|
{# duplicate rule #}
|
||||||
<a href="{{ route('rules.duplicate',rule.id) }}" class="btn btn-default"
|
<a href="{{ route('rules.duplicate',rule.id) }}" class="btn btn-default"
|
||||||
title=" {{ trans('firefly.duplicate_rule', {title: rule.title}) }}">
|
title=" {{ trans('firefly.duplicate_rule', {title: rule.title}) }}">
|
||||||
|
Reference in New Issue
Block a user