diff --git a/erpnext/accounts/report/trial_balance/trial_balance.js b/erpnext/accounts/report/trial_balance/trial_balance.js index e3f32ab974f..e91073a962c 100644 --- a/erpnext/accounts/report/trial_balance/trial_balance.js +++ b/erpnext/accounts/report/trial_balance/trial_balance.js @@ -122,6 +122,7 @@ frappe.query_reports["Trial Balance"] = { tree: true, name_field: "account", parent_field: "parent_account", + export_hidden_cols: true, initial_depth: 3, }; diff --git a/erpnext/accounts/report/trial_balance/trial_balance.py b/erpnext/accounts/report/trial_balance/trial_balance.py index 587a8ea95cb..df6e547eae3 100644 --- a/erpnext/accounts/report/trial_balance/trial_balance.py +++ b/erpnext/accounts/report/trial_balance/trial_balance.py @@ -402,6 +402,8 @@ def prepare_data(accounts, filters, parent_children_map, company_currency): "to_date": filters.to_date, "currency": company_currency, "is_group_account": d.is_group, + "acc_name": d.account_name, + "acc_number": d.account_number, "account_name": ( f"{d.account_number} - {d.account_name}" if d.account_number else d.account_name ), @@ -436,6 +438,20 @@ def get_columns(): "options": "Account", "width": 300, }, + { + "fieldname": "acc_name", + "label": _("Account Name"), + "fieldtype": "Data", + "hidden": 1, + "width": 250, + }, + { + "fieldname": "acc_number", + "label": _("Account Number"), + "fieldtype": "Data", + "hidden": 1, + "width": 120, + }, { "fieldname": "currency", "label": _("Currency"),