Files
admin-vben5/apps/web-antd/src/views/property/roomBooking/participants/data.ts
2025-09-04 09:29:53 +08:00

66 lines
1.3 KiB
TypeScript

import type { FormSchemaGetter } from '#/adapter/form';
import type { VxeGridProps } from '#/adapter/vxe-table';
export const querySchema: FormSchemaGetter = () => [
{
component: 'Input',
fieldName: 'meetId',
label: '会议室id',
},
{
component: 'Input',
fieldName: 'residentPersonId',
label: '入驻人员id',
},
];
// 需要使用i18n注意这里要改成getter形式 否则切换语言不会刷新
// export const columns: () => VxeGridProps['columns'] = () => [
export const columns: VxeGridProps['columns'] = [
{ type: 'checkbox', width: 60 },
{
title: '主键id',
field: 'id',
},
{
title: '会议室id',
field: 'meetId',
},
{
title: '入驻人员id',
field: 'residentPersonId',
},
{
field: 'action',
fixed: 'right',
slots: { default: 'action' },
title: '操作',
width: 180,
},
];
export const modalSchema: FormSchemaGetter = () => [
{
label: '主键id',
fieldName: 'id',
component: 'Input',
dependencies: {
show: () => false,
triggerFields: [''],
},
},
{
label: '会议室id',
fieldName: 'meetId',
component: 'Input',
rules: 'required',
},
{
label: '入驻人员id',
fieldName: 'residentPersonId',
component: 'Input',
rules: 'required',
},
];