Moved the format_amount and format_date template filters from the "accounting.transaction.template_filters" module to the "accounting.template_filters" module, and rename the filters from "accounting_txn_format_amount" and "accounting_txn_format_date" to "accounting_format_amount" and "accounting_format_date", respectively. They will not only be used in the transaction management, but also the reports.
This commit is contained in:
@ -58,6 +58,10 @@ def init_app(app: Flask, user_utils: AbstractUserUtils,
|
||||
template_folder="templates",
|
||||
static_folder="static")
|
||||
|
||||
from .template_filters import format_amount, format_date
|
||||
bp.add_app_template_filter(format_amount, "accounting_format_amount")
|
||||
bp.add_app_template_filter(format_date, "accounting_format_date")
|
||||
|
||||
from . import locale
|
||||
locale.init_app(app, bp)
|
||||
|
||||
|
Reference in New Issue
Block a user