import { AutoScrollTable } from '@btri-ui/base';
import React from 'react';

const MaintenanceScatter = () => {
  const data = [
    {
      a1: 'WB1131R2003',
      a2: '2021/8/16 8:28',
      a3: '尹建峰',
      a4: '21K000842',
      a5: '合格',
    },
    {
      a1: 'WB1131R2004',
      a2: '2021/8/16 8:45',
      a3: '武长城',
      a4: '15K002703',
      a5: '合格',
    },
    {
      a1: 'WB1131R2005',
      a2: '2021/8/16 10:18',
      a3: '金鑫',
      a4: '17K002194',
      a5: '合格',
    },
    {
      a1: 'WB1131R2006',
      a2: '2021/8/16 12:12',
      a3: '尹建峰',
      a4: '21K000842',
      a5: '合格',
    },
    {
      a1: 'WB1131R2009',
      a2: '2021/8/16 18:48',
      a3: '金鑫',
      a4: '20H001731',
      a5: '合格',
    },
    {
      a1: 'WB1131R2009',
      a2: '2021/8/16 15:13',
      a3: '尹建峰',
      a4: '21J000072',
      a5: '合格',
    },
    {
      a1: 'WB1131R2003',
      a2: '2021/8/16 8:28',
      a3: '尹建峰',
      a4: '21K000992',
      a5: '合格',
    },
  ];

  const columns = [
    {
      title: '维保单号',
      dataIndex: 'a1',
      style: {
        color: '#70cce1',
      },
    },
    { title: '开始时间', dataIndex: 'a2' },
    { title: '维保员', dataIndex: 'a3' },
    {
      title: '电梯ID',
      dataIndex: 'a4',
      render: (_: any) => <div style={{ color: '#70cce1' }}>{_}</div>,
    },
    { title: '维保结果', dataIndex: 'a5' },
  ];

  return (
    <div style={{ height: '100%' }}>
      <AutoScrollTable columns={columns} data={data} height="15rem" />
    </div>
  );
};

export default MaintenanceScatter;
