From 79c12bdb9c6f74b2e45cd1d032ae42722540512c Mon Sep 17 00:00:00 2001 From: Shariq Ansari Date: Sat, 3 Feb 2024 21:16:59 +0530 Subject: [PATCH] fix: return correct total_count --- crm/api/doc.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/crm/api/doc.py b/crm/api/doc.py index 3afb7f7df..bbafda0f7 100644 --- a/crm/api/doc.py +++ b/crm/api/doc.py @@ -236,7 +236,7 @@ def get_list_data( "page_length_count": page_length_count, "is_default": is_default, "views": get_views(doctype), - "total_count": frappe.client.get_count(doctype, filters=filters), + "total_count": len(frappe.get_all(doctype, filters=filters)), "row_count": len(data), }