Make sure all controllers can store attachment when creating models #2828

This commit is contained in:
James Cole
2020-03-19 09:01:35 +01:00
parent d489244c00
commit 12e81364a0
5 changed files with 39 additions and 2 deletions

View File

@@ -190,8 +190,7 @@ class EditController extends Controller
$request->session()->flash('success', (string) trans('firefly.updated_account', ['name' => $account->name]));
app('preferences')->mark();
// store new attachments
// store attachment(s):
// store new attachment(s):
/** @var array $files */
$files = $request->hasFile('attachments') ? $request->file('attachments') : null;
$this->attachments->saveAttachmentsForModel($account, $files);