Add notes to audit report.

This commit is contained in:
James Cole
2024-12-23 08:35:33 +01:00
parent ae09200f42
commit e1785898ba
3 changed files with 10 additions and 2 deletions

View File

@@ -83,6 +83,9 @@ class MonthReportGenerator implements ReportGeneratorInterface
'create_date',
'update_date',
// more
'notes',
// date fields.
'interest_date',
'book_date',
@@ -126,7 +129,7 @@ class MonthReportGenerator implements ReportGeneratorInterface
/** @var GroupCollectorInterface $collector */
$collector = app(GroupCollectorInterface::class);
$collector->setAccounts(new Collection([$account]))->setRange($this->start, $this->end)->withAccountInformation()
->withBudgetInformation()->withCategoryInformation()->withBillInformation()
->withBudgetInformation()->withCategoryInformation()->withBillInformation()->withNotes()
;
$journals = $collector->getExtractedJournals();
$journals = array_reverse($journals, true);

View File

@@ -58,7 +58,7 @@
account_name: account.name|escape,
url: url,
end: auditData[account.id].dayBefore,
balance: formatAmountByAccount(account, auditData[account.id].dayBeforeBalance)
balance: formatAmountByAccount(account, auditData[account.id].dayBeforeBalance.balance)
})|raw }}
</p>
{% include 'reports.partials.journals-audit' with {'journals': auditData[account.id].journals,'account':account} %}

View File

@@ -22,6 +22,8 @@
<th class="hide-create_date">{{ trans('list.create_date') }}</th>
<th class="hide-update_date">{{ trans('list.update_date') }}</th>
<th class="hide-notes">{{ trans('list.notes') }}</th>
{# even more optional fields #}
<th class="hide-interest_date">{{ trans('list.interest_date') }}</th>
<th class="hide-book_date">{{ trans('list.book_date') }}</th>
@@ -144,6 +146,9 @@
<td class="hide-update_date">
{{ journal.updated_at.isoFormat(dateTimeFormat) }}
</td>
<td class="hide-notes">
{{ journal.notes|default('')|markdown }}
</td>
<!-- more new dates -->
<td class="hide-interest_date">