export const employee = () => {
  return [{
    field: 'index',
    label: '序号',
    align: 'center',
  }, {
    field: 'gunCode',
    operation: true,
    label: '充装枪编号',
    align: 'center',
  }, {
    field: 'scanGunCode',
    label: '扫描枪编号',
    align: 'center',
  }, {
    field: 'personCode',
    label: '充装人员',
    align: 'center',
    options: [],
  }, {
    field: 'remark',
    label: '备注',
    align: 'center',
  }, {
    field: 'action',
    label: '操作',
    colWidth: '200px',
    align: 'center',
    labelButton: [{
      type: 'edit',
      label: '编辑',
      icon: 'el-icon-edit',
      style: 'primary',
    }, {
      type: 'del',
      label: '删除',
      icon: 'el-icon-tickets',
      style: 'danger',
    }]
  }]
}

export const formRules = () => {
  return [{
    field: 'gunCode',
    label: '充装枪编号',
    placeholder: '充装枪编号',
    type: 'input',
    colWidth: 24,
    rules: [{
      required: true,
      message: '请输入充装枪编号',
      trigger: 'blur'
    }]
  }, {
    field: 'scanGunCode',
    label: '扫描枪编号',
    placeholder: '扫描枪编号',
    type: 'input',
    colWidth: 24,
    rules: [{
      required: true,
      message: '请输入扫描枪编号',
      trigger: 'blur'
    }]
  }, {
    field: 'personCode',
    type: 'select',
    label: '充装人员',
    placeholder: '请选择',
    colWidth: 24,
    rules: [{
      required: true,
      message: '请选择充装人员',
      trigger: 'change'
    }],
    options: [],
  }, {
    field: 'remark',
    label: '备注',
    placeholder: '备注',
    type: 'textarea',
    colWidth: 24,
  }, ]
}
