Revised the documentation of the CSV rows for the reports.

This commit is contained in:
依瑪貓 2023-03-08 17:21:14 +08:00
parent 5dc8387ad9
commit 11ab4a4ba6
7 changed files with 16 additions and 16 deletions

View File

@ -259,10 +259,10 @@ class AccountCollector:
class CSVHalfRow: class CSVHalfRow:
"""A half row in the CSV balance sheet.""" """A half row in the CSV."""
def __init__(self, title: str | None, amount: Decimal | None): def __init__(self, title: str | None, amount: Decimal | None):
"""The constructs a half row in the CSV balance sheet. """The constructs a half row in the CSV.
:param title: The title. :param title: The title.
:param amount: The amount. :param amount: The amount.
@ -274,10 +274,10 @@ class CSVHalfRow:
class CSVRow(BaseCSVRow): class CSVRow(BaseCSVRow):
"""A row in the CSV balance sheet.""" """A row in the CSV."""
def __init__(self): def __init__(self):
"""Constructs a row in the CSV balance sheet.""" """Constructs a row in the CSV."""
self.asset_title: str | None = None self.asset_title: str | None = None
"""The title of the asset.""" """The title of the asset."""
self.asset_amount: Decimal | None = None self.asset_amount: Decimal | None = None

View File

@ -202,7 +202,7 @@ class EntryCollector:
class CSVRow(BaseCSVRow): class CSVRow(BaseCSVRow):
"""A row in the CSV income and expenses log.""" """A row in the CSV."""
def __init__(self, txn_date: date | str | None, def __init__(self, txn_date: date | str | None,
account: str | None, account: str | None,
@ -211,7 +211,7 @@ class CSVRow(BaseCSVRow):
expense: str | Decimal | None, expense: str | Decimal | None,
balance: str | Decimal | None, balance: str | Decimal | None,
note: str | None): note: str | None):
"""Constructs a row in the CSV income and expenses log. """Constructs a row in the CSV.
:param txn_date: The transaction date. :param txn_date: The transaction date.
:param account: The account. :param account: The account.

View File

@ -116,10 +116,10 @@ class IncomeStatementSection:
class CSVRow(BaseCSVRow): class CSVRow(BaseCSVRow):
"""A row in the CSV income statement.""" """A row in the CSV."""
def __init__(self, text: str | None, amount: str | Decimal | None): def __init__(self, text: str | None, amount: str | Decimal | None):
"""Constructs a row in the CSV income statement. """Constructs a row in the CSV.
:param text: The text. :param text: The text.
:param amount: The amount. :param amount: The amount.

View File

@ -71,7 +71,7 @@ class Entry:
class CSVRow(BaseCSVRow): class CSVRow(BaseCSVRow):
"""A row in the CSV journal.""" """A row in the CSV."""
def __init__(self, txn_date: str | date, def __init__(self, txn_date: str | date,
currency: str, currency: str,
@ -80,7 +80,7 @@ class CSVRow(BaseCSVRow):
debit: str | Decimal | None, debit: str | Decimal | None,
credit: str | Decimal | None, credit: str | Decimal | None,
note: str | None): note: str | None):
"""Constructs a row in the CSV journal. """Constructs a row in the CSV.
:param txn_date: The transaction date. :param txn_date: The transaction date.
:param summary: The summary. :param summary: The summary.

View File

@ -183,7 +183,7 @@ class EntryCollector:
class CSVRow(BaseCSVRow): class CSVRow(BaseCSVRow):
"""A row in the CSV ledger.""" """A row in the CSV."""
def __init__(self, txn_date: date | str | None, def __init__(self, txn_date: date | str | None,
summary: str | None, summary: str | None,
@ -191,7 +191,7 @@ class CSVRow(BaseCSVRow):
credit: str | Decimal | None, credit: str | Decimal | None,
balance: str | Decimal | None, balance: str | Decimal | None,
note: str | None): note: str | None):
"""Constructs a row in the CSV ledger. """Constructs a row in the CSV.
:param txn_date: The transaction date. :param txn_date: The transaction date.
:param summary: The summary. :param summary: The summary.

View File

@ -70,7 +70,7 @@ class Entry:
class CSVRow(BaseCSVRow): class CSVRow(BaseCSVRow):
"""A row in the CSV search result.""" """A row in the CSV."""
def __init__(self, txn_date: str | date, def __init__(self, txn_date: str | date,
currency: str, currency: str,
@ -79,7 +79,7 @@ class CSVRow(BaseCSVRow):
debit: str | Decimal | None, debit: str | Decimal | None,
credit: str | Decimal | None, credit: str | Decimal | None,
note: str | None): note: str | None):
"""Constructs a row in the CSV search result. """Constructs a row in the CSV.
:param txn_date: The transaction date. :param txn_date: The transaction date.
:param summary: The summary. :param summary: The summary.

View File

@ -71,12 +71,12 @@ class TrialBalanceTotal:
class CSVRow(BaseCSVRow): class CSVRow(BaseCSVRow):
"""A row in the CSV trial balance.""" """A row in the CSV."""
def __init__(self, text: str | None, def __init__(self, text: str | None,
debit: str | Decimal | None, debit: str | Decimal | None,
credit: str | Decimal | None): credit: str | Decimal | None):
"""Constructs a row in the CSV trial balance. """Constructs a row in the CSV.
:param text: The text. :param text: The text.
:param debit: The debit amount. :param debit: The debit amount.