mirror of
https://github.com/hibiken/asynqmon.git
synced 2025-10-24 07:16:12 +08:00
(ui): Convert all tasks tables to use TasksTable component
This commit is contained in:
@@ -74,17 +74,6 @@ const columns: TableColumn[] = [
|
||||
{ key: "actions", label: "Actions", align: "center" },
|
||||
];
|
||||
|
||||
function ScheduledTasksTable(props: Props & ReduxProps) {
|
||||
return (
|
||||
<TasksTable
|
||||
taskState="scheduled"
|
||||
columns={columns}
|
||||
renderRow={(rowProps: RowProps) => <Row {...rowProps} />}
|
||||
{...props}
|
||||
/>
|
||||
);
|
||||
}
|
||||
|
||||
function Row(props: RowProps) {
|
||||
const { task } = props;
|
||||
const classes = useRowStyles();
|
||||
@@ -187,4 +176,15 @@ function Row(props: RowProps) {
|
||||
);
|
||||
}
|
||||
|
||||
function ScheduledTasksTable(props: Props & ReduxProps) {
|
||||
return (
|
||||
<TasksTable
|
||||
taskState="scheduled"
|
||||
columns={columns}
|
||||
renderRow={(rowProps: RowProps) => <Row {...rowProps} />}
|
||||
{...props}
|
||||
/>
|
||||
);
|
||||
}
|
||||
|
||||
export default connector(ScheduledTasksTable);
|
||||
|
||||
Reference in New Issue
Block a user