import type { FormSchemaGetter } from '#/adapter/form';
import type { VxeGridProps } from '#/adapter/vxe-table';

export const queryFormSchema: FormSchemaGetter = () => [
  {
    component: 'Input',
    fieldName: 'examPaperName',
    label: '考卷名称',
    componentProps: {
      placeholder: '请输入考卷名称',
    },
  },
];

export const tableColumns: VxeGridProps['columns'] = [
  {
    field: 'examPaperName',
    title: '考卷名称',
    minWidth: 150,
  },
  {
    field: 'createTime',
    title: '创建时间',
    minWidth: 120,
  },
  {
    field: 'endTime',
    title: '截止时间',
    minWidth: 120,
  },
  {
    field: 'totalNum',
    title: '发放人数',
    minWidth: 100,
  },
  {
    field: 'participateNum',
    title: '参与人数',
    minWidth: 100,
  },
  {
    field: 'markedNum',
    title: '已批改人数',
    minWidth: 100,
  },
  {
    field: 'unmarkedNum',
    title: '未批改人数',
    minWidth: 100,
  },
  {
    field: 'action',
    fixed: 'right',
    slots: { default: 'action' },
    title: '操作',
    width: 150,
  },
];
