mirror of
https://github.com/firefly-iii/firefly-iii.git
synced 2025-11-20 16:40:10 +00:00
Reformat various code.
This commit is contained in:
@@ -102,7 +102,7 @@ class InterestingMessage
|
||||
|
||||
// send message about newly created transaction group.
|
||||
/** @var TransactionGroup $group */
|
||||
$group = auth()->user()->transactionGroups()->with(['transactionJournals', 'transactionJournals.transactionType'])->find((int)$transactionGroupId);
|
||||
$group = auth()->user()->transactionGroups()->with(['transactionJournals', 'transactionJournals.transactionType'])->find((int) $transactionGroupId);
|
||||
|
||||
if (null === $group) {
|
||||
return;
|
||||
@@ -118,17 +118,17 @@ class InterestingMessage
|
||||
$title = $count > 1 ? $group->title : $journal->description;
|
||||
if ('created' === $message) {
|
||||
session()->flash('success_url', route('transactions.show', [$transactionGroupId]));
|
||||
session()->flash('success', (string)trans('firefly.stored_journal', ['description' => $title]));
|
||||
session()->flash('success', (string) trans('firefly.stored_journal', ['description' => $title]));
|
||||
}
|
||||
if ('updated' === $message) {
|
||||
$type = strtolower($journal->transactionType->type);
|
||||
session()->flash('success_url', route('transactions.show', [$transactionGroupId]));
|
||||
session()->flash('success', (string)trans(sprintf('firefly.updated_%s', $type), ['description' => $title]));
|
||||
session()->flash('success', (string) trans(sprintf('firefly.updated_%s', $type), ['description' => $title]));
|
||||
}
|
||||
if ('no_change' === $message) {
|
||||
$type = strtolower($journal->transactionType->type);
|
||||
session()->flash('warning_url', route('transactions.show', [$transactionGroupId]));
|
||||
session()->flash('warning', (string)trans(sprintf('firefly.no_changes_%s', $type), ['description' => $title]));
|
||||
session()->flash('warning', (string) trans(sprintf('firefly.no_changes_%s', $type), ['description' => $title]));
|
||||
}
|
||||
}
|
||||
|
||||
@@ -163,13 +163,13 @@ class InterestingMessage
|
||||
return;
|
||||
}
|
||||
if ('deleted' === $message) {
|
||||
session()->flash('success', (string)trans('firefly.account_deleted', ['name' => $account->name]));
|
||||
session()->flash('success', (string) trans('firefly.account_deleted', ['name' => $account->name]));
|
||||
}
|
||||
if ('created' === $message) {
|
||||
session()->flash('success', (string)trans('firefly.stored_new_account', ['name' => $account->name]));
|
||||
session()->flash('success', (string) trans('firefly.stored_new_account', ['name' => $account->name]));
|
||||
}
|
||||
if ('updated' === $message) {
|
||||
session()->flash('success', (string)trans('firefly.updated_account', ['name' => $account->name]));
|
||||
session()->flash('success', (string) trans('firefly.updated_account', ['name' => $account->name]));
|
||||
}
|
||||
}
|
||||
|
||||
@@ -204,10 +204,10 @@ class InterestingMessage
|
||||
return;
|
||||
}
|
||||
if ('deleted' === $message) {
|
||||
session()->flash('success', (string)trans('firefly.deleted_bill', ['name' => $bill->name]));
|
||||
session()->flash('success', (string) trans('firefly.deleted_bill', ['name' => $bill->name]));
|
||||
}
|
||||
if ('created' === $message) {
|
||||
session()->flash('success', (string)trans('firefly.stored_new_bill', ['name' => $bill->name]));
|
||||
session()->flash('success', (string) trans('firefly.stored_new_bill', ['name' => $bill->name]));
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user