fix: 平台管理路由改为扁平结构测试

This commit is contained in:
小蟑螂
2026-03-30 22:38:22 +08:00
parent b9f9c2feb7
commit f24a970aa7
@@ -2,79 +2,89 @@ import type { RouteRecordRaw } from 'vue-router';
const routes: RouteRecordRaw[] = [ const routes: RouteRecordRaw[] = [
{ {
meta: { name: 'SystemPlatformCompany',
icon: 'lucide:shield',
order: 100,
title: '平台管理',
},
name: 'SystemPlatform',
path: '/platform-admin',
children: [
{
name: 'PlatformCompanyManagement',
path: '/platform-admin/company', path: '/platform-admin/company',
component: () => import('#/views/organization/company/index.vue'), component: () => import('#/views/organization/company/index.vue'),
meta: { meta: {
icon: 'lucide:building', icon: 'lucide:building',
title: '公司管理', title: '公司管理',
requiresAuth: true,
}, },
}, },
{ {
name: 'PlatformMenuManagement', name: 'SystemPlatformMenu',
path: '/platform-admin/menu', path: '/platform-admin/menu',
component: () => import('#/views/system/menu/index.vue'), component: () => import('#/views/system/menu/index.vue'),
meta: { meta: {
icon: 'lucide:menu', icon: 'lucide:menu',
title: '菜单管理', title: '菜单管理',
requiresAuth: true,
}, },
}, },
{ {
name: 'PlatformPermissionManagement', name: 'SystemPlatformPermission',
path: '/platform-admin/permission', path: '/platform-admin/permission',
component: () => import('#/views/system/permission/index.vue'), component: () => import('#/views/system/permission/index.vue'),
meta: { meta: {
icon: 'lucide:shield-check', icon: 'lucide:shield-check',
title: '权限码管理', title: '权限码管理',
requiresAuth: true,
}, },
}, },
{ {
name: 'PlatformFieldManagement', name: 'SystemPlatformField',
path: '/platform-admin/field', path: '/platform-admin/field',
component: () => import('#/views/system/field/index.vue'), component: () => import('#/views/system/field/index.vue'),
meta: { meta: {
icon: 'lucide:database', icon: 'lucide:database',
title: '字段管理', title: '字段管理',
requiresAuth: true,
}, },
}, },
{ {
name: 'PlatformAccountSuperManagement', name: 'SystemPlatformAccountSuper',
path: '/platform-admin/account-super', path: '/platform-admin/account-super',
component: () => import('#/views/organization/account-super/index.vue'), component: () =>
import('#/views/organization/account-super/index.vue'),
meta: { meta: {
icon: 'lucide:user-check', icon: 'lucide:user-check',
title: '账户管理-超管', title: '账户管理-超管',
requiresAuth: true,
}, },
}, },
{ {
name: 'PlatformCompanyMenuAssign', name: 'SystemPlatformCompanyMenuManage',
path: '/platform-admin/company-menu-manage', path: '/platform-admin/company-menu-manage',
component: () => import('#/views/system/platform/company-menu-manage.vue'), component: () =>
import('#/views/system/platform/company-menu-manage.vue'),
meta: { meta: {
icon: 'lucide:layoutDashboard', icon: 'lucide:layoutDashboard',
title: '公司菜单管理', title: '公司菜单管理',
requiresAuth: true,
}, },
}, },
{ {
name: 'PlatformCompanyPermissionAssign', name: 'SystemPlatformCompanyPermissionManage',
path: '/platform-admin/company-permission-manage', path: '/platform-admin/company-permission-manage',
component: () => import('#/views/system/platform/company-permission-manage.vue'), component: () =>
import(
'#/views/system/platform/company-permission-manage.vue'
),
meta: { meta: {
icon: 'lucide:shield-check', icon: 'lucide:shield-check',
title: '公司权限管理', title: '公司权限管理',
requiresAuth: true,
}, },
}, },
],
},
]; ];
export default routes; export default routes;
// TEST route - delete after testing
import { h } from 'vue';
const TestRoute: RouteRecordRaw = {
name: 'TestRoute',
path: '/test',
component: () => Promise.resolve({ render: () => h('div', 'TEST PAGE WORKS') }),
meta: { title: 'Test', requiresAuth: true },
};