mirror of
https://github.com/firefly-iii/firefly-iii.git
synced 2025-02-25 18:45:27 -06:00
Fix some tests.
This commit is contained in:
@@ -65,10 +65,10 @@ class SplitJournalFormRequest extends Request
|
||||
switch ($data['type']) {
|
||||
case 'withdrawal':
|
||||
$sourceId = $this->integer('journal_source_account_id');
|
||||
$destinationName = $transaction['destination_name'];
|
||||
$destinationName = $transaction['destination_name'] ?? '';
|
||||
break;
|
||||
case 'deposit':
|
||||
$sourceName = $transaction['source_name'];
|
||||
$sourceName = $transaction['source_name'] ?? '';
|
||||
$destinationId = $this->integer('journal_destination_account_id');
|
||||
break;
|
||||
case 'transfer':
|
||||
|
||||
@@ -150,7 +150,7 @@ class AccountTransformer extends TransformerAbstract
|
||||
if (strlen($role) === 0 || $type !== AccountType::ASSET) {
|
||||
$role = null;
|
||||
}
|
||||
$currencyId = (int)$this->repository->getMetaValue($account, 'currency_id');
|
||||
$currencyId = intval($this->repository->getMetaValue($account, 'currency_id'));
|
||||
$currencyCode = null;
|
||||
$decimalPlaces = 2;
|
||||
if ($currencyId > 0) {
|
||||
@@ -197,7 +197,7 @@ class AccountTransformer extends TransformerAbstract
|
||||
'currency_code' => $currencyCode,
|
||||
'current_balance' => round(app('steam')->balance($account, $date), $decimalPlaces),
|
||||
'current_balance_date' => $date->format('Y-m-d'),
|
||||
'notes' => $this->repository->getNote($account),
|
||||
'notes' => $this->repository->getNoteText($account),
|
||||
'monthly_payment_date' => $monthlyPaymentDate,
|
||||
'credit_card_type' => $creditCardType,
|
||||
'account_number' => $this->repository->getMetaValue($account, 'accountNumber'),
|
||||
|
||||
Reference in New Issue
Block a user