import React from 'react';
import { Table } from 'antd';
import { FormattedMessage } from 'react-intl';

interface PatientData {
  key: string;
  name: string;
  id: string;
  priority: string;
  status: string;
  retryCount: number;
  target: string;
}

const columns = [
  {
    title: (
      <FormattedMessage
        id="outputTable.name"
        defaultMessage="outputTable.name"
      />
    ),
    dataIndex: 'name',
    key: 'name',
  },
  {
    title: (
      <FormattedMessage id="outputTable.id" defaultMessage="outputTable.id" />
    ),
    dataIndex: 'id',
    key: 'id',
  },
  {
    title: (
      <FormattedMessage
        id="outputTable.priority"
        defaultMessage="outputTable.priority"
      />
    ),
    dataIndex: 'priority',
    key: 'priority',
  },
  {
    title: (
      <FormattedMessage
        id="outputTable.status"
        defaultMessage="outputTable.status"
      />
    ),
    dataIndex: 'status',
    key: 'status',
  },
  {
    title: (
      <FormattedMessage
        id="outputTable.retryCount"
        defaultMessage="outputTable.retryCount"
      />
    ),
    dataIndex: 'retryCount',
    key: 'retryCount',
  },
  {
    title: (
      <FormattedMessage
        id="outputTable.target"
        defaultMessage="outputTable.target"
      />
    ),
    dataIndex: 'target',
    key: 'target',
  },
];

const data: PatientData[] = [
  // 示例数据，可根据实际情况替换
  // {
  //   key: '1',
  //   name: '张三',
  //   id: 'P001',
  //   priority: '高',
  //   status: '处理中',
  //   retryCount: 2,
  //   target: '目标A',
  // },
];

const OutputTable: React.FC = () => (
  <Table columns={columns} dataSource={data} />
);

export default OutputTable;
