feat: benchmark detail actions

This commit is contained in:
jialin
2026-02-01 22:56:36 +08:00
parent 0849a2f114
commit 9796233897
12 changed files with 268 additions and 103 deletions
@@ -53,15 +53,18 @@ const actionList = [
interface RowActionsProps {
record: ListItem;
page?: 'detail' | 'list';
handleSelect: (key: string, record: ListItem) => void;
}
const RowActions: React.FC<RowActionsProps> = (props) => {
const { record, handleSelect } = props;
const { record, handleSelect, page = 'list' } = props;
const { onDownloadLog, contextHolder } = useDownloadLogs();
const actions = actionList.filter((action) => {
if (action.status && action.status.length > 0) {
if (page === 'detail' && action.key === 'edit') {
return false;
} else if (action.status && action.status.length > 0) {
return action.status?.includes(record.state);
}