Payment Pending List — “Submitted By” Filter Not Sorted Alphabetically
This commit is contained in:
parent
8f83d91d25
commit
03207a3318
@ -180,9 +180,14 @@ const PaymentRequestList = ({ filters, groupBy = "submittedBy", search }) => {
|
||||
];
|
||||
if (isLoading) return <ExpenseTableSkeleton headers={header} />;
|
||||
|
||||
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" },
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user