diff --git a/yudao-ui-admin-vue3/src/router/index.ts b/yudao-ui-admin-vue3/src/router/index.ts
index 4d2d079ea..4fe42b515 100644
--- a/yudao-ui-admin-vue3/src/router/index.ts
+++ b/yudao-ui-admin-vue3/src/router/index.ts
@@ -14,7 +14,7 @@ import { usePermissionStoreWithOut } from '@/store/modules/permission'
import { getInfoApi } from '@/api/login'
import { listSimpleDictDataApi } from '@/api/system/dict/dict.data'
-const { wsCache } = useCache('sessionStorage')
+const { wsCache } = useCache()
const { start, done } = useNProgress()
diff --git a/yudao-ui-admin-vue3/src/views/system/dept/dept.data.ts b/yudao-ui-admin-vue3/src/views/system/dept/dept.data.ts
index f199c3e43..2515266f5 100644
--- a/yudao-ui-admin-vue3/src/views/system/dept/dept.data.ts
+++ b/yudao-ui-admin-vue3/src/views/system/dept/dept.data.ts
@@ -12,8 +12,7 @@ export const rules = reactive({
email: [required],
phone: [
{
- min: 11,
- max: 11,
+ len: 11,
trigger: 'blur',
message: '请输入正确的手机号码'
}
diff --git a/yudao-ui-admin-vue3/src/views/system/dept/index.vue b/yudao-ui-admin-vue3/src/views/system/dept/index.vue
index d03f2124a..6a5b50e66 100644
--- a/yudao-ui-admin-vue3/src/views/system/dept/index.vue
+++ b/yudao-ui-admin-vue3/src/views/system/dept/index.vue
@@ -75,16 +75,15 @@
diff --git a/yudao-ui-admin-vue3/src/views/system/menu/menu.data.ts b/yudao-ui-admin-vue3/src/views/system/menu/menu.data.ts
new file mode 100644
index 000000000..625a2b851
--- /dev/null
+++ b/yudao-ui-admin-vue3/src/views/system/menu/menu.data.ts
@@ -0,0 +1,73 @@
+import { reactive } from 'vue'
+import { useI18n } from '@/hooks/web/useI18n'
+import { DICT_TYPE } from '@/utils/dict'
+import { required } from '@/utils/formRules'
+import { VxeCrudSchema, useVxeCrudSchemas } from '@/hooks/web/useVxeCrudSchemas'
+const { t } = useI18n() // 国际化
+
+// 新增和修改的表单校验
+export const rules = reactive({
+ name: [required],
+ sort: [required],
+ path: [required],
+ status: [required]
+})
+
+// CrudSchema
+const crudSchemas = reactive({
+ primaryKey: 'id',
+ primaryType: null,
+ action: true,
+ columns: [
+ {
+ title: '上级菜单',
+ field: 'parentId',
+ isTable: false
+ },
+ {
+ title: '菜单名称',
+ field: 'name',
+ isSearch: true,
+ table: {
+ treeNode: true,
+ align: 'left',
+ width: '200px'
+ }
+ },
+ {
+ title: '菜单类型',
+ field: 'type',
+ dictType: DICT_TYPE.SYSTEM_MENU_TYPE
+ },
+ {
+ title: '路由地址',
+ field: 'path'
+ },
+ {
+ title: '组件路径',
+ field: 'component'
+ },
+ {
+ title: '权限标识',
+ field: 'permission'
+ },
+ {
+ title: '排序',
+ field: 'sort'
+ },
+ {
+ title: t('common.status'),
+ field: 'status',
+ dictType: DICT_TYPE.COMMON_STATUS,
+ dictClass: 'number',
+ isSearch: true
+ },
+ {
+ title: t('common.createTime'),
+ field: 'createTime',
+ formatter: 'formatDate',
+ isForm: false
+ }
+ ]
+})
+export const { allSchemas } = useVxeCrudSchemas(crudSchemas)