mirror of
https://github.com/firefly-iii/firefly-iii.git
synced 2025-09-30 18:41:08 +00:00
Fix split edit.
This commit is contained in:
@@ -267,8 +267,8 @@ class SplitController extends Controller
|
|||||||
// take some info from first transaction, that should at least exist.
|
// take some info from first transaction, that should at least exist.
|
||||||
$array[$index] = $row;
|
$array[$index] = $row;
|
||||||
$array[$index]['currency_id'] = $array[0]['transaction_currency_id'];
|
$array[$index]['currency_id'] = $array[0]['transaction_currency_id'];
|
||||||
$array[$index]['currency_code'] = $array[0]['transaction_currency_code'];
|
$array[$index]['currency_code'] = $array[0]['transaction_currency_code'] ?? '';
|
||||||
$array[$index]['currency_symbol'] = $array[0]['transaction_currency_symbol'];
|
$array[$index]['currency_symbol'] = $array[0]['transaction_currency_symbol'] ?? '';
|
||||||
$array[$index]['foreign_amount'] = round($array[0]['foreign_destination_amount'] ?? '0', 12);
|
$array[$index]['foreign_amount'] = round($array[0]['foreign_destination_amount'] ?? '0', 12);
|
||||||
$array[$index]['foreign_currency_id'] = $array[0]['foreign_currency_id'];
|
$array[$index]['foreign_currency_id'] = $array[0]['foreign_currency_id'];
|
||||||
$array[$index]['foreign_currency_code'] = $array[0]['foreign_currency_code'];
|
$array[$index]['foreign_currency_code'] = $array[0]['foreign_currency_code'];
|
||||||
|
@@ -90,12 +90,12 @@ class SplitJournalFormRequest extends Request
|
|||||||
'identifier' => $index,
|
'identifier' => $index,
|
||||||
'currency_id' => $this->integer('journal_currency_id'),
|
'currency_id' => $this->integer('journal_currency_id'),
|
||||||
'currency_code' => null,
|
'currency_code' => null,
|
||||||
'description' => $transaction['transaction_description'],
|
'description' => $transaction['transaction_description'] ?? '',
|
||||||
'amount' => $transaction['amount'],
|
'amount' => $transaction['amount'],
|
||||||
'budget_id' => (int)($transaction['budget_id'] ?? 0.0),
|
'budget_id' => (int)($transaction['budget_id'] ?? 0.0),
|
||||||
'budget_name' => null,
|
'budget_name' => null,
|
||||||
'category_id' => null,
|
'category_id' => null,
|
||||||
'category_name' => $transaction['category_name'],
|
'category_name' => $transaction['category_name'] ?? '',
|
||||||
];
|
];
|
||||||
$data['transactions'][] = $set;
|
$data['transactions'][] = $set;
|
||||||
}
|
}
|
||||||
|
Reference in New Issue
Block a user