From 1c44d93b93ba071f7ac453d1110dcdab548c41b8 Mon Sep 17 00:00:00 2001 From: Sharath C Date: Wed, 3 Oct 2018 10:41:11 +0530 Subject: [PATCH] Is frozen and Disabled Columns added to Customer Credit Report (#15560) --- .../customer_credit_balance.py | 14 +++++++++----- 1 file changed, 9 insertions(+), 5 deletions(-) diff --git a/erpnext/selling/report/customer_credit_balance/customer_credit_balance.py b/erpnext/selling/report/customer_credit_balance/customer_credit_balance.py index ffa418017cd..fe58af61c82 100644 --- a/erpnext/selling/report/customer_credit_balance/customer_credit_balance.py +++ b/erpnext/selling/report/customer_credit_balance/customer_credit_balance.py @@ -29,9 +29,11 @@ def execute(filters=None): if customer_naming_type == "Naming Series": row = [d.name, d.customer_name, credit_limit, outstanding_amt, bal, - d.bypass_credit_limit_check_at_sales_order] + d.bypass_credit_limit_check_at_sales_order, d.is_frozen, + d.disabled] else: - row = [d.name, credit_limit, outstanding_amt, bal, d.bypass_credit_limit_check_at_sales_order] + row = [d.name, credit_limit, outstanding_amt, bal, + d.bypass_credit_limit_check_at_sales_order, d.is_frozen, d.disabled] if credit_limit: data.append(row) @@ -44,7 +46,9 @@ def get_columns(customer_naming_type): _("Credit Limit") + ":Currency:120", _("Outstanding Amt") + ":Currency:100", _("Credit Balance") + ":Currency:120", - _("Bypass credit check at Sales Order ") + ":Check:240" + _("Bypass credit check at Sales Order ") + ":Check:80", + _("Is Frozen") + ":Check:80", + _("Disabled") + ":Check:80", ] if customer_naming_type == "Naming Series": @@ -59,5 +63,5 @@ def get_details(filters): conditions += " where name = %(customer)s" return frappe.db.sql("""select name, customer_name, - bypass_credit_limit_check_at_sales_order from `tabCustomer` %s - """ % conditions, filters, as_dict=1) \ No newline at end of file + bypass_credit_limit_check_at_sales_order, is_frozen, disabled from `tabCustomer` %s + """ % conditions, filters, as_dict=1)