|
|
|
|
const routes = [
|
|
|
|
|
// Public
|
|
|
|
|
{ path: '/login', component: '/page/auth/login.html', layout: 'public' },
|
|
|
|
|
{ path: '/register', component: '/page/auth/register.html', layout: 'public' },
|
|
|
|
|
|
|
|
|
|
// Dashboard (Default Layout)
|
|
|
|
|
{
|
|
|
|
|
path: '/',
|
|
|
|
|
layout: 'default',
|
|
|
|
|
meta: { auth: true },
|
|
|
|
|
component: '/page/dashboard/index.html'
|
|
|
|
|
},
|
|
|
|
|
|
|
|
|
|
// Org Management
|
|
|
|
|
{ path: '/org', component: '/page/sys/org/index.html', layout: 'default', meta: { auth: true } },
|
|
|
|
|
{
|
|
|
|
|
path: '/org/:id',
|
|
|
|
|
component: '/page/sys/org/detail.html',
|
|
|
|
|
layout: 'default',
|
|
|
|
|
meta: { auth: true }
|
|
|
|
|
},
|
|
|
|
|
|
|
|
|
|
// User System
|
|
|
|
|
{ path: '/profile', component: '/page/user/profile.html', layout: 'default', meta: { auth: true } },
|
|
|
|
|
{
|
|
|
|
|
path: '/users',
|
|
|
|
|
component: '/page/sys/user/index.html',
|
|
|
|
|
layout: 'default',
|
|
|
|
|
meta: { auth: true, roles: ['admin'] }
|
|
|
|
|
},
|
|
|
|
|
|
|
|
|
|
// OAuth Management
|
|
|
|
|
{ path: '/oauth/apps', component: '/page/sys/oauth/index.html', layout: 'default', meta: { auth: true } },
|
|
|
|
|
|
|
|
|
|
// Errors
|
|
|
|
|
{ path: '/403', component: '/page/403.html', layout: 'public' },
|
|
|
|
|
{ path: '*', component: '/page/404.html', layout: 'public' }
|
|
|
|
|
]
|
|
|
|
|
|
|
|
|
|
export default routes
|