From fbe5d128a81e08b1a2da193093036da2077f5807 Mon Sep 17 00:00:00 2001 From: Shllokkk <140623894+Shllokkk@users.noreply.github.com> Date: Tue, 31 Mar 2026 23:38:19 +0530 Subject: [PATCH] feat: sticky column in various reports (#53960) Co-authored-by: diptanilsaha Co-authored-by: mihir-kandoi --- .../accounts_receivable_summary.py | 2 ++ erpnext/stock/report/stock_ageing/stock_ageing.py | 2 ++ erpnext/stock/report/stock_balance/stock_balance.py | 4 ++++ .../stock/report/stock_projected_qty/stock_projected_qty.py | 2 ++ 4 files changed, 10 insertions(+) diff --git a/erpnext/accounts/report/accounts_receivable_summary/accounts_receivable_summary.py b/erpnext/accounts/report/accounts_receivable_summary/accounts_receivable_summary.py index a15a2e1193f..3ae6fab4df7 100644 --- a/erpnext/accounts/report/accounts_receivable_summary/accounts_receivable_summary.py +++ b/erpnext/accounts/report/accounts_receivable_summary/accounts_receivable_summary.py @@ -149,6 +149,7 @@ class AccountsReceivableSummary(ReceivablePayableReport): fieldtype="Dynamic Link", options="party_type", width=180, + sticky=(self.party_naming_by not in ["Naming Series", "Auto Name"]), ) if self.party_naming_by == "Naming Series": @@ -156,6 +157,7 @@ class AccountsReceivableSummary(ReceivablePayableReport): label=_("Supplier Name") if self.account_type == "Payable" else _("Customer Name"), fieldname="party_name", fieldtype="Data", + sticky=True, ) credit_debit_label = "Credit Note" if self.account_type == "Receivable" else "Debit Note" diff --git a/erpnext/stock/report/stock_ageing/stock_ageing.py b/erpnext/stock/report/stock_ageing/stock_ageing.py index 2ea52e91a8d..2624f323200 100644 --- a/erpnext/stock/report/stock_ageing/stock_ageing.py +++ b/erpnext/stock/report/stock_ageing/stock_ageing.py @@ -135,6 +135,7 @@ def get_columns(filters: Filters) -> list[dict]: "fieldtype": "Link", "options": "Item", "width": 100, + "sticky": "True", }, {"label": _("Item Name"), "fieldname": "item_name", "fieldtype": "Data", "width": 100}, {"label": _("Description"), "fieldname": "description", "fieldtype": "Data", "width": 200}, @@ -162,6 +163,7 @@ def get_columns(filters: Filters) -> list[dict]: "fieldtype": "Link", "options": "Warehouse", "width": 100, + "sticky": "True", } ] diff --git a/erpnext/stock/report/stock_balance/stock_balance.py b/erpnext/stock/report/stock_balance/stock_balance.py index 7d96d6a6d6b..ace9a13f5ad 100644 --- a/erpnext/stock/report/stock_balance/stock_balance.py +++ b/erpnext/stock/report/stock_balance/stock_balance.py @@ -475,6 +475,7 @@ class StockBalanceReport: "fieldtype": "Link", "options": "Item", "width": 100, + "sticky": "True", }, {"label": _("Item Name"), "fieldname": "item_name", "width": 150}, { @@ -490,6 +491,7 @@ class StockBalanceReport: "fieldtype": "Link", "options": "Warehouse", "width": 100, + "sticky": "True", }, ] @@ -520,6 +522,7 @@ class StockBalanceReport: "fieldtype": "Float", "width": 100, "convertible": "qty", + "sticky": "True", }, { "label": _("Balance Value"), @@ -527,6 +530,7 @@ class StockBalanceReport: "fieldtype": "Currency", "width": 100, "options": "Company:company:default_currency", + "sticky": "True", }, { "label": _("Opening Qty"), diff --git a/erpnext/stock/report/stock_projected_qty/stock_projected_qty.py b/erpnext/stock/report/stock_projected_qty/stock_projected_qty.py index 3193ba3de51..7fc128980b4 100644 --- a/erpnext/stock/report/stock_projected_qty/stock_projected_qty.py +++ b/erpnext/stock/report/stock_projected_qty/stock_projected_qty.py @@ -106,6 +106,7 @@ def get_columns(): "fieldtype": "Link", "options": "Item", "width": 140, + "sticky": "True", }, {"label": _("Item Name"), "fieldname": "item_name", "width": 100}, {"label": _("Description"), "fieldname": "description", "width": 200}, @@ -129,6 +130,7 @@ def get_columns(): "fieldtype": "Link", "options": "Warehouse", "width": 120, + "sticky": "True", }, { "label": _("UOM"),