mirror of
https://github.com/firefly-iii/firefly-iii.git
synced 2025-02-25 18:45:27 -06:00
New version
This commit is contained in:
parent
0cab974048
commit
63a7a4b03b
@ -122,6 +122,16 @@ trait DepositValidation
|
|||||||
$result = false;
|
$result = false;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// if there is an iban, it can only be in use by a revenue account or we will fail.
|
||||||
|
if(null !== $accountIban && '' !== $accountIban) {
|
||||||
|
app('log')->debug('Check if there is not already an account with this IBAN');
|
||||||
|
$existing = $this->findExistingAccount([AccountType::ASSET, AccountType::LOAN, AccountType::DEBT, AccountType::MORTGAGE], ['iban' => $accountIban]);
|
||||||
|
if(null !== $existing) {
|
||||||
|
$this->destError = (string)trans('validation.deposit_src_iban_exists');
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
// if the user submits an ID, but that ID is not of the correct type,
|
// if the user submits an ID, but that ID is not of the correct type,
|
||||||
// return false.
|
// return false.
|
||||||
if (null !== $accountId) {
|
if (null !== $accountId) {
|
||||||
|
Loading…
Reference in New Issue
Block a user