Ultraworked with [Sisyphus](https://github.com/code-yeongyu/oh-my-openagent) Co-authored-by: Sisyphus <clio-agent@sisyphuslabs.ai>
54 lines
1.2 KiB
TypeScript
54 lines
1.2 KiB
TypeScript
import { createRouter, createWebHashHistory } from 'vue-router'
|
|
|
|
const router = createRouter({
|
|
history: createWebHashHistory(),
|
|
routes: [
|
|
{
|
|
path: '/',
|
|
redirect: '/tasks',
|
|
},
|
|
{
|
|
path: '/jobs',
|
|
name: 'JobsList',
|
|
component: () => import('@/views/Jobs/List.vue'),
|
|
meta: { title: '任务列表' },
|
|
},
|
|
{
|
|
path: '/jobs/history',
|
|
name: 'JobsHistory',
|
|
component: () => import('@/views/Jobs/History.vue'),
|
|
meta: { title: '任务历史' },
|
|
},
|
|
{
|
|
path: '/jobs/:id',
|
|
name: 'JobsDetail',
|
|
component: () => import('@/views/Jobs/Detail.vue'),
|
|
meta: { title: '任务详情' },
|
|
},
|
|
{
|
|
path: '/tasks',
|
|
name: 'TasksList',
|
|
component: () => import('@/views/Tasks/List.vue'),
|
|
meta: { title: '任务列表' },
|
|
},
|
|
{
|
|
path: '/tasks/create',
|
|
name: 'TasksCreate',
|
|
component: () => import('@/views/Tasks/Submit.vue'),
|
|
meta: { title: '提交任务' },
|
|
},
|
|
{
|
|
path: '/files',
|
|
name: 'FilesList',
|
|
component: () => import('@/views/Files/List.vue'),
|
|
meta: { title: '文件管理' },
|
|
},
|
|
{
|
|
path: '/:pathMatch(.*)*',
|
|
redirect: '/tasks',
|
|
},
|
|
],
|
|
})
|
|
|
|
export default router
|