feat: 支持i18n菜单

This commit is contained in:
dap
2024-10-11 09:29:06 +08:00
parent f707fcb3da
commit 27f62c2bab
3 changed files with 113 additions and 0 deletions

View File

@@ -1,4 +1,5 @@
import { DictEnum } from '@vben/constants';
import { $t } from '@vben/locales';
import { getPopupContainer } from '@vben/utils';
import { type FormSchemaGetter, type VxeGridProps, z } from '#/adapter';
@@ -56,6 +57,10 @@ export const columns: VxeGridProps['columns'] = [
field: 'menuName',
treeNode: true,
width: 200,
slots: {
// 需要i18n支持 否则返回原始值
default: ({ row }) => $t(row.menuName),
},
},
{
title: '图标',