import { ModuleDataChart } from '/@/components/Configurable/types';
import { BasicColumn } from '/@/components/Table';
import { alarmCellRender } from '/@/views/monitor/sealedMonitor/monitor.data';

export const boardData = [
  {
    label: '存在风险情况数量',
    value: '-',
  },
  {
    label: '低风险',
    value: '-',
  },
  {
    label: '一般风险',
    value: '-',
  },
  {
    label: '较高风险',
    value: '-',
  },
  {
    label: '高风险',
    value: '-',
  },
];
// 实时数据相关
export const columns: BasicColumn[] = [
  {
    title: '区域',
    dataIndex: 'areaName',
    fixed: 'left',
    width: 100,
  },
  {
    title: '煤矿名称',
    dataIndex: 'mineName',
    fixed: 'left',
    width: 200,
  },
  {
    title: '老空区永久密闭名称',
    dataIndex: 'devicePos',
    fixed: 'left',
    width: 200,
  },
  {
    title: '所属煤层',
    dataIndex: 'coalSeamName',
    width: 100,
  },
  {
    title: '自燃倾向性',
    dataIndex: 'coalSeamLevel',
    width: 100,
  },
  {
    title: 'CO(ppm)',
    dataIndex: 'coVal',
    width: 100,
  },
  {
    title: 'CH4(%)',
    dataIndex: 'ch4Val',
    width: 100,
  },
  {
    title: 'C2H4(ppm)',
    dataIndex: 'c2h4Val',
    width: 100,
  },
  {
    title: 'C2H2(ppm)',
    dataIndex: 'c2h2Val',
    width: 100,
  },
  {
    title: 'O2(%)',
    dataIndex: 'o2Val',
    width: 100,
  },
  {
    title: '爆炸危险性',
    dataIndex: 'alarmName',
    width: 100,
    customRender({ record }) {
      return alarmCellRender(record);
    },
  },
  // {
  //   title: '处置意见',
  //   dataIndex: 'suggestion',
  //   width: 100,
  // },
  {
    title: '分析时间',
    dataIndex: 'createTime',
    width: 100,
  },
  {
    title: '是否解决',
    customRender: () => '未解决',
    width: 100,
  },
];

interface ModalDetailsData {
  basicInfo: Record<string, any>[];
  board: Record<string, any>[];
  gasConcentrationConfig?: ModuleDataChart;
  pressureConfig?: ModuleDataChart;
  blastDeltaConfig?: Record<string, any>;
}
export const modalDetailsData: ModalDetailsData = {
  basicInfo: [
    {
      label: '煤矿名称',
      value: 'mineName',
    },
    {
      label: '设备位置',
      value: 'devicePos',
    },
    {
      label: '爆炸危险性',
      value: 'alarmLevel',
      customRender({ record }) {
        return alarmCellRender(record);
      },
    },
  ],
  board: [
    {
      label: 'CO(ppm)',
      value: 'coVal',
    },
    {
      label: 'CH4(%)',
      value: 'ch4Val',
    },
    {
      label: 'C2H4(ppm)',
      value: 'c2h4Val',
    },
    {
      label: 'C2H2(ppm)',
      value: 'c2h2Val',
    },
    {
      label: 'O2(%)',
      value: 'o2Val',
    },
  ],
  blastDeltaConfig: {},
};
