import { $t } from '#/locales';

/**
 * 列
 */
const columns = [
  // {
  //   title: $t('robot.group.groupCode'),
  //   dataIndex: 'groupCode',
  //  
  // },
  {
    title: $t('robot.group.groupName'),
    dataIndex: 'groupName',
   
  },
  {
    title: $t('robot.group.notes'),
    dataIndex: 'notes',
   
  },
  {
    title: $t('robot.group.status'),
    dataIndex: 'status',
   
  },
  {
    title: $t('robot.group.createTime'),
    dataIndex: 'createTime',
sorter: true,
  },
  {
    title: $t('robot.group.creator'),
    dataIndex: 'creator',
   
  },
  {
    title: $t('common.action'),
    dataIndex: 'action',
    fixed: 'right',
    width: 160
  }
]

/**
 * 状态映射
 */
const statusMap = {
  0: $t('robot.group.statusOptions.v0'),
  1: $t('robot.group.statusOptions.v1'),
}

/**
 * 查询参数
 */
const query = {
  groupCode: '',
  groupName: '',
  notes: '',
  status: undefined,
  creator: ''
};

export const d = {
  isShowQuery: true,
  loading: false,
  pagination: {
    total: 0,
    current: 1,
    pageSize: 10,
    showTotal: (total, range) => `共 ${total} 条`,
    showSizeChanger: true,
    pageSizeOptions: ['10', '20', '50', '100', '500', '1000'],
    showQuickJumper: true,
  },
  datas: [],
  query,
  columns,
  statusMap,
}