From 03207a3318ebeb44d7cb4c8807199365136c2980 Mon Sep 17 00:00:00 2001 From: Kartik Sharma Date: Fri, 7 Nov 2025 11:55:00 +0530 Subject: [PATCH] =?UTF-8?q?Payment=20Pending=20List=20=E2=80=94=20?= =?UTF-8?q?=E2=80=9CSubmitted=20By=E2=80=9D=20Filter=20Not=20Sorted=20Alph?= =?UTF-8?q?abetically?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/components/PaymentRequest/PaymentRequestList.jsx | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) diff --git a/src/components/PaymentRequest/PaymentRequestList.jsx b/src/components/PaymentRequest/PaymentRequestList.jsx index 061601fa..32b21988 100644 --- a/src/components/PaymentRequest/PaymentRequestList.jsx +++ b/src/components/PaymentRequest/PaymentRequestList.jsx @@ -180,9 +180,14 @@ const PaymentRequestList = ({ filters, groupBy = "submittedBy", search }) => { ]; if (isLoading) return ; - const grouped = groupBy - ? groupByField(data?.data ?? [], groupBy) + const grouped = groupBy + ? Object.fromEntries( + Object.entries(groupByField(data?.data ?? [], groupBy)).sort(([keyA], [keyB]) => + keyA.localeCompare(keyB) + ) + ) : { All: data?.data ?? [] }; + const IsGroupedByDate = [ { key: "transactionDate", displayField: "Transaction Date" }, { key: "createdAt", displayField: "created Date" },