'[Feature]新增删除Group或GroupOffset功能(didi#1040)'

This commit is contained in:
erge
2023-09-10 16:14:48 +08:00
parent d1417bef8c
commit 6385889902
5 changed files with 157 additions and 6 deletions

View File

@@ -1,8 +1,9 @@
/* eslint-disable @typescript-eslint/explicit-module-boundary-types */
import React from 'react';
import { AppContainer } from 'knowdesign';
import { AppContainer, Button, Popconfirm } from 'knowdesign';
import TagsWithHide from '@src/components/TagsWithHide';
import { ClustersPermissionMap } from '../CommonConfig';
import Delete from './Delete';
export const runningStatusEnum: any = {
1: 'Doing',
@@ -62,6 +63,21 @@ export const getGroupColumns = (arg?: any) => {
width: 200,
render: (t: number) => (t ? t.toLocaleString() : '-'),
},
{
title: '操作',
dataIndex: 'options',
key: 'options',
width: 200,
filterTitle: true,
fixed: 'right',
render: (_t: any, r: any) => {
return (
<div>
<Delete record={r} onConfirm={arg?.deleteTesk}></Delete>
</div>
);
},
},
];
return columns;
};
@@ -103,11 +119,20 @@ export const getGtoupTopicColumns = (arg?: any) => {
title: '操作',
dataIndex: 'desc',
key: 'desc',
width: 150,
width: 200,
render: (value: any, record: any) => {
return (
<div>
<a onClick={() => arg.resetOffset(record)}>Offset</a>
<Popconfirm
placement="top"
title={`是否要删除当前Topic`}
onConfirm={() => arg.deleteOffset(record)}
okText="是"
cancelText="否"
>
<Button type="link"></Button>
</Popconfirm>
</div>
);
},