mirror of
https://github.com/firefly-iii/firefly-iii.git
synced 2026-01-07 14:41:20 +00:00
Auto commit for release 'branch-v6.2' on 2024-12-14
This commit is contained in:
@@ -61,6 +61,7 @@ class PiggyBankUpdateRequest extends FormRequest
|
||||
foreach ($accounts as $item) {
|
||||
$data['accounts'][] = ['account_id' => (int) $item];
|
||||
}
|
||||
|
||||
return $data;
|
||||
}
|
||||
|
||||
@@ -106,7 +107,7 @@ class PiggyBankUpdateRequest extends FormRequest
|
||||
if ($accountCurrency->id !== $currency->id && 'true' !== $isMultiCurrency) {
|
||||
$validator->errors()->add('accounts', trans('validation.invalid_account_currency'));
|
||||
}
|
||||
$type = $account->accountType->type;
|
||||
$type = $account->accountType->type;
|
||||
if (!in_array($type, $types, true)) {
|
||||
$validator->errors()->add('accounts', trans('validation.invalid_account_type'));
|
||||
}
|
||||
@@ -121,6 +122,7 @@ class PiggyBankUpdateRequest extends FormRequest
|
||||
Log::channel('audit')->error(sprintf('Validation errors in %s', __CLASS__), $validator->errors()->toArray());
|
||||
}
|
||||
}
|
||||
|
||||
private function getCurrencyFromData(array $data): TransactionCurrency
|
||||
{
|
||||
$currencyId = (int) ($data['transaction_currency_id'] ?? 0);
|
||||
|
||||
Reference in New Issue
Block a user