feat: search form

This commit is contained in:
dap
2024-09-24 11:23:02 +08:00
parent c5971e4407
commit c1e58831e1
32 changed files with 924 additions and 49 deletions

View File

@@ -1,8 +1,40 @@
import { DictEnum } from '@vben/constants';
import { getPopupContainer } from '@vben/utils';
import { type FormSchemaGetter, z } from '#/adapter';
import { getDictOptions } from '#/utils/dict';
export const querySchema: FormSchemaGetter = () => [
{
component: 'Input',
componentProps: {
placeholder: '请输入',
},
fieldName: 'menuName',
label: '菜单名称 ',
},
{
component: 'Select',
componentProps: {
getPopupContainer,
options: getDictOptions(DictEnum.SYS_NORMAL_DISABLE),
placeholder: '请选择',
},
fieldName: 'status',
label: '菜单状态 ',
},
{
component: 'Select',
componentProps: {
getPopupContainer,
options: getDictOptions(DictEnum.SYS_SHOW_HIDE),
placeholder: '请选择',
},
fieldName: 'visible',
label: '显示状态',
},
];
// 菜单类型M目录 C菜单 F按钮
export const menuTypeOptions = [
{ label: '目录', value: 'M' },