2025-06-24 23:55:59 +08:00
|
|
|
|
import type { FormSchemaGetter } from '#/adapter/form';
|
|
|
|
|
import type { VxeGridProps } from '#/adapter/vxe-table';
|
|
|
|
|
|
|
|
|
|
export const querySchema: FormSchemaGetter = () => [
|
|
|
|
|
{
|
|
|
|
|
component: 'Input',
|
|
|
|
|
fieldName: 'libCode',
|
|
|
|
|
label: '人员库编码',
|
|
|
|
|
},
|
|
|
|
|
{
|
|
|
|
|
component: 'Input',
|
|
|
|
|
fieldName: 'imgName',
|
|
|
|
|
label: '人像名称',
|
|
|
|
|
},
|
|
|
|
|
{
|
|
|
|
|
component: 'Input',
|
|
|
|
|
fieldName: 'imgCode',
|
|
|
|
|
label: '图片编码',
|
|
|
|
|
},
|
|
|
|
|
{
|
|
|
|
|
component: 'Input',
|
|
|
|
|
fieldName: 'imgUrl',
|
|
|
|
|
label: '图片的存储地址',
|
|
|
|
|
},
|
|
|
|
|
{
|
|
|
|
|
component: 'Select',
|
2025-06-25 00:37:48 +08:00
|
|
|
|
componentProps: {},
|
2025-06-24 23:55:59 +08:00
|
|
|
|
fieldName: 'sex',
|
2025-06-25 00:37:48 +08:00
|
|
|
|
label: '性别',
|
2025-06-24 23:55:59 +08:00
|
|
|
|
},
|
|
|
|
|
{
|
|
|
|
|
component: 'Input',
|
|
|
|
|
fieldName: 'email',
|
|
|
|
|
label: '邮箱',
|
|
|
|
|
},
|
|
|
|
|
{
|
|
|
|
|
component: 'Input',
|
|
|
|
|
fieldName: 'tel',
|
|
|
|
|
label: '联系方式',
|
|
|
|
|
},
|
|
|
|
|
{
|
|
|
|
|
component: 'Select',
|
2025-06-25 00:37:48 +08:00
|
|
|
|
componentProps: {},
|
2025-06-24 23:55:59 +08:00
|
|
|
|
fieldName: 'certificateType',
|
2025-06-25 00:37:48 +08:00
|
|
|
|
label: '证件类型',
|
2025-06-24 23:55:59 +08:00
|
|
|
|
},
|
|
|
|
|
{
|
|
|
|
|
component: 'Input',
|
|
|
|
|
fieldName: 'certificateNo',
|
|
|
|
|
label: '证件号码',
|
|
|
|
|
},
|
|
|
|
|
{
|
|
|
|
|
component: 'Input',
|
|
|
|
|
fieldName: 'birthDate',
|
|
|
|
|
label: '出生日期',
|
|
|
|
|
},
|
|
|
|
|
{
|
|
|
|
|
component: 'Input',
|
|
|
|
|
fieldName: 'createById',
|
|
|
|
|
label: '创建人id',
|
|
|
|
|
},
|
|
|
|
|
{
|
|
|
|
|
component: 'Input',
|
|
|
|
|
fieldName: 'updateById',
|
|
|
|
|
label: '更新人id',
|
|
|
|
|
},
|
|
|
|
|
{
|
|
|
|
|
component: 'Input',
|
|
|
|
|
fieldName: 'searchValue',
|
|
|
|
|
label: '搜索值',
|
|
|
|
|
},
|
|
|
|
|
];
|
|
|
|
|
|
|
|
|
|
// 需要使用i18n注意这里要改成getter形式 否则切换语言不会刷新
|
|
|
|
|
// export const columns: () => VxeGridProps['columns'] = () => [
|
|
|
|
|
export const columns: VxeGridProps['columns'] = [
|
|
|
|
|
{ type: 'checkbox', width: 60 },
|
|
|
|
|
{
|
|
|
|
|
title: '主键id',
|
|
|
|
|
field: 'id',
|
|
|
|
|
},
|
|
|
|
|
{
|
|
|
|
|
title: '人员库编码',
|
|
|
|
|
field: 'libCode',
|
|
|
|
|
},
|
|
|
|
|
{
|
|
|
|
|
title: '人像名称',
|
|
|
|
|
field: 'imgName',
|
|
|
|
|
},
|
|
|
|
|
{
|
|
|
|
|
title: '图片编码',
|
|
|
|
|
field: 'imgCode',
|
|
|
|
|
},
|
|
|
|
|
{
|
|
|
|
|
title: '图片的存储地址',
|
|
|
|
|
field: 'imgUrl',
|
|
|
|
|
},
|
|
|
|
|
{
|
2025-06-25 00:37:48 +08:00
|
|
|
|
title: '性别',
|
2025-06-24 23:55:59 +08:00
|
|
|
|
},
|
|
|
|
|
{
|
|
|
|
|
title: '邮箱',
|
|
|
|
|
field: 'email',
|
|
|
|
|
},
|
|
|
|
|
{
|
|
|
|
|
title: '联系方式',
|
|
|
|
|
field: 'tel',
|
|
|
|
|
},
|
|
|
|
|
{
|
2025-06-25 00:37:48 +08:00
|
|
|
|
title: '证件类型',
|
2025-06-24 23:55:59 +08:00
|
|
|
|
field: 'certificateType',
|
|
|
|
|
},
|
|
|
|
|
{
|
|
|
|
|
title: '证件号码',
|
|
|
|
|
field: 'certificateNo',
|
|
|
|
|
},
|
|
|
|
|
{
|
|
|
|
|
title: '出生日期',
|
|
|
|
|
field: 'birthDate',
|
|
|
|
|
},
|
|
|
|
|
{
|
|
|
|
|
title: '创建人id',
|
|
|
|
|
field: 'createById',
|
|
|
|
|
},
|
|
|
|
|
{
|
|
|
|
|
title: '更新人id',
|
|
|
|
|
field: 'updateById',
|
|
|
|
|
},
|
|
|
|
|
{
|
|
|
|
|
title: '搜索值',
|
|
|
|
|
field: 'searchValue',
|
|
|
|
|
},
|
|
|
|
|
{
|
|
|
|
|
field: 'action',
|
|
|
|
|
fixed: 'right',
|
2025-06-25 00:37:48 +08:00
|
|
|
|
slots: {
|
|
|
|
|
default: 'action',
|
|
|
|
|
},
|
2025-06-24 23:55:59 +08:00
|
|
|
|
title: '操作',
|
|
|
|
|
width: 180,
|
|
|
|
|
},
|
|
|
|
|
];
|
|
|
|
|
|
|
|
|
|
export const modalSchema: FormSchemaGetter = () => [
|
|
|
|
|
{
|
|
|
|
|
label: '主键id',
|
|
|
|
|
fieldName: 'id',
|
|
|
|
|
component: 'Input',
|
|
|
|
|
dependencies: {
|
|
|
|
|
show: () => false,
|
|
|
|
|
triggerFields: [''],
|
|
|
|
|
},
|
|
|
|
|
},
|
|
|
|
|
{
|
|
|
|
|
label: '人员库编码',
|
|
|
|
|
fieldName: 'libCode',
|
|
|
|
|
component: 'Input',
|
|
|
|
|
rules: 'required',
|
|
|
|
|
},
|
|
|
|
|
{
|
|
|
|
|
label: '人像名称',
|
|
|
|
|
fieldName: 'imgName',
|
|
|
|
|
component: 'Input',
|
|
|
|
|
rules: 'required',
|
|
|
|
|
},
|
|
|
|
|
{
|
|
|
|
|
label: '图片编码',
|
|
|
|
|
fieldName: 'imgCode',
|
|
|
|
|
component: 'Input',
|
|
|
|
|
},
|
|
|
|
|
{
|
|
|
|
|
label: '图片的存储地址',
|
|
|
|
|
fieldName: 'imgUrl',
|
|
|
|
|
component: 'Input',
|
|
|
|
|
rules: 'required',
|
|
|
|
|
},
|
|
|
|
|
{
|
2025-06-25 00:37:48 +08:00
|
|
|
|
label: '性别 1:男',
|
2025-06-24 23:55:59 +08:00
|
|
|
|
fieldName: 'sex',
|
|
|
|
|
component: 'Select',
|
2025-06-25 00:37:48 +08:00
|
|
|
|
componentProps: {},
|
2025-06-24 23:55:59 +08:00
|
|
|
|
},
|
|
|
|
|
{
|
|
|
|
|
label: '邮箱',
|
|
|
|
|
fieldName: 'email',
|
|
|
|
|
component: 'Input',
|
|
|
|
|
},
|
|
|
|
|
{
|
|
|
|
|
label: '联系方式',
|
|
|
|
|
fieldName: 'tel',
|
|
|
|
|
component: 'Input',
|
|
|
|
|
},
|
|
|
|
|
{
|
2025-06-25 00:37:48 +08:00
|
|
|
|
label: '证件类型',
|
2025-06-24 23:55:59 +08:00
|
|
|
|
fieldName: 'certificateType',
|
|
|
|
|
component: 'Select',
|
2025-06-25 00:37:48 +08:00
|
|
|
|
componentProps: {},
|
2025-06-24 23:55:59 +08:00
|
|
|
|
},
|
|
|
|
|
{
|
|
|
|
|
label: '证件号码',
|
|
|
|
|
fieldName: 'certificateNo',
|
|
|
|
|
component: 'Input',
|
|
|
|
|
},
|
|
|
|
|
{
|
|
|
|
|
label: '出生日期',
|
|
|
|
|
fieldName: 'birthDate',
|
|
|
|
|
component: 'Input',
|
|
|
|
|
},
|
|
|
|
|
{
|
|
|
|
|
label: '创建人id',
|
|
|
|
|
fieldName: 'createById',
|
|
|
|
|
component: 'Input',
|
|
|
|
|
},
|
|
|
|
|
{
|
|
|
|
|
label: '更新人id',
|
|
|
|
|
fieldName: 'updateById',
|
|
|
|
|
component: 'Input',
|
|
|
|
|
},
|
|
|
|
|
{
|
|
|
|
|
label: '搜索值',
|
|
|
|
|
fieldName: 'searchValue',
|
|
|
|
|
component: 'Input',
|
|
|
|
|
},
|
|
|
|
|
];
|