Various cleanup in transaction and journal display code.

This commit is contained in:
James Cole
2017-11-04 07:10:21 +01:00
parent b4dc70244a
commit bb46d034cd
25 changed files with 885 additions and 543 deletions

View File

@@ -123,7 +123,8 @@ class JournalTasker implements JournalTaskerInterface
]
);
$transactions = [];
$transactions = [];
$transactionType = $journal->transactionType->type;
/** @var Transaction $entry */
foreach ($set as $entry) {
@@ -132,6 +133,8 @@ class JournalTasker implements JournalTaskerInterface
$budget = $entry->budgets->first();
$category = $entry->categories->first();
$transaction = [
'journal_type' => $transactionType,
'updated_at' => $journal->updated_at,
'source_id' => $entry->id,
'source_amount' => $entry->amount,
'foreign_source_amount' => $entry->foreign_amount,