import { FormConfig } from '@/types/basic-form';

export const EVALUATION_SYSTEM_FORM_CONFIG: FormConfig[] = [
  {
    prop: 'evaluationTableName',
    label: '考核表名称：',
    component: 'ElInput',
    componentProps: {
      placeholder: '请输入考核表名称',
    },
  },
  {
    prop: 'attachmentDocument',
    label: '上传附件文档：',
    slot: 'attachmentDocument',
  },
  {
    prop: 'scoringDescription',
    label: '评分说明：',
    component: 'ElInput',
    componentProps: {
      type: 'textarea',
      rows: 5,
      placeholder: '请输入评分说明',
    },
  },
];

export const EVALUATION_SYSTEM_FORM_DATA = {
  evaluationTableName: '',
  attachmentDocument: [],
  scoringDescription: '',
};

export const EVALUATION_SYSTEM_FORM_RULES = {
  evaluationTableName: [{ required: true, message: '请输入考核表名称', trigger: 'blur' }],
  attachmentDocument: [{ required: true, message: '请上传附件文档', trigger: 'change' }],
  scoringDescription: [{ required: true, message: '请输入评分说明', trigger: 'blur' }],
};
