From 857d01cecfd815e3000c8db592f8c37067e21cb8 Mon Sep 17 00:00:00 2001 From: Gavin D'souza Date: Wed, 1 Feb 2023 13:53:37 +0530 Subject: [PATCH] fix: Fetch all fields via get_returned_qty_map_for_row (cherry picked from commit 940ad6e3f2883db5225e0bee37cb0196faf6e7e9) --- erpnext/controllers/sales_and_purchase_return.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/erpnext/controllers/sales_and_purchase_return.py b/erpnext/controllers/sales_and_purchase_return.py index 1e7dcfb2b6d..c4f8fc17064 100644 --- a/erpnext/controllers/sales_and_purchase_return.py +++ b/erpnext/controllers/sales_and_purchase_return.py @@ -301,7 +301,7 @@ def get_returned_qty_map_for_row(return_against, party, row_name, doctype): fields += ["sum(abs(`tab{0}`.received_stock_qty)) as received_stock_qty".format(child_doctype)] # Used retrun against and supplier and is_retrun because there is an index added for it - data = frappe.db.get_list( + data = frappe.get_all( doctype, fields=fields, filters=[