feat(ui): add sortable column support to DataTable and implement in flows

This commit is contained in:
Rafif-Riqullah-Siregar committed 2026-07-10 15:23:47 +07:00
1 parent 525b9ceead
commit 83da34a1ab
2 files changed
+54 -7

No files matched your search

+6 -2
View File
@@ -117,11 +117,15 @@ export default function FlowsPage() {
},
{
header: "Download",
accessor: (row) => <span className="text-blue-400">{fmtBytes(row.bytes_download)}</span>
accessor: (row) => <span className="text-blue-400">{fmtBytes(row.bytes_download)}</span>,
sortable: true,
sortAccessor: (row) => row.bytes_download ?? 0
},
{
header: "Upload",
accessor: (row) => <span className="text-green-500">{fmtBytes(row.bytes_upload)}</span>
accessor: (row) => <span className="text-green-500">{fmtBytes(row.bytes_upload)}</span>,
sortable: true,
sortAccessor: (row) => row.bytes_upload ?? 0
}
];