From c21f0793215d1bc5020d52c32daa5169d875c1f3 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E4=BE=9D=E7=91=AA=E8=B2=93?= Date: Sat, 18 Jul 2020 08:46:30 +0800 Subject: [PATCH] Fixed the date of the brought-forward record in the accounting application. --- accounting/views/__init__.py | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/accounting/views/__init__.py b/accounting/views/__init__.py index 707d5ad..eb68fc0 100644 --- a/accounting/views/__init__.py +++ b/accounting/views/__init__.py @@ -420,8 +420,7 @@ def ledger(request, subject_code, period_spec): is_credit=True, then=-1), default=1) * F("amount")))["balance"] record_brought_forward = Record( - transaction=Transaction( - date=records[-1].transaction.date), + transaction=Transaction(date=period.start), subject=current_subject, summary=pgettext("Accounting|", "Brought Forward"), is_credit=balance < 0,