show status on ui

This commit is contained in:
Ishaan Jaff 2025-02-28 09:32:39 -08:00
parent e8b6d7caa2
commit 3ba518979e

View file

@ -56,6 +56,24 @@ export const columns: ColumnDef<LogEntry>[] = [
accessorKey: "startTime",
cell: (info: any) => <TimeCell utcTime={info.getValue()} />,
},
{
header: "Status",
accessorKey: "metadata.status",
cell: (info: any) => {
const status = info.getValue() || "Success";
const isSuccess = status.toLowerCase() !== "failure";
return (
<span className={`px-2 py-1 rounded-md text-xs font-medium inline-block text-center w-16 ${
isSuccess
? 'bg-green-100 text-green-800'
: 'bg-red-100 text-red-800'
}`}>
{isSuccess ? "Success" : "Failure"}
</span>
);
},
},
{
header: "Request ID",
accessorKey: "request_id",