123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566 |
- import {ActionType, PageContainer, ProTable,} from '@ant-design/pro-components';
- import {Card} from 'antd';
- import React, {useRef} from 'react';
- import {getPeakListApi} from '@/services/swagger/peakAdmin';
- const Peak: React.FC = () => {
- const ref = useRef<ActionType>();
- return (
- <PageContainer content={''}>
- <Card>
- <ProTable<SectApi.StaffVO>
- rowKey={'id'}
- request={async (_) => {
- const res = await getPeakListApi();
- return {
- success: res.success,
- data: res.data,
- };
- }}
- columns={[
- {
- title: 'ID',
- dataIndex: 'id',
- },
- {
- title: '名称',
- dataIndex: 'name',
- },
- {
- title: '等级',
- dataIndex: 'name',
- },
- {
- title: '人数',
- dataIndex: 'mobile',
- },
- {
- title: '经验值',
- dataIndex: 'nickname',
- },
- {
- title: '操作',
- valueType: 'option',
- render: () => [
- <a key={'stat'}>查看数据</a>,
- <a key={'details'}>基础信息</a>,
- ],
- },
- ]
- }
- pagination={false}
- search={false}
- form={{
- ignoreRules: false,
- }}
- actionRef={ref}
- ></ProTable>
- </Card>
- </PageContainer>
- );
- };
- export default Peak;
|