forked from artefactual-labs/enduro
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathrouter.ts
92 lines (87 loc) · 2.06 KB
/
router.ts
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
import Vue from 'vue';
import Router from 'vue-router';
import Batch from './views/Batch.vue';
import Collections from './views/Collections.vue';
import CollectionList from './views/CollectionList.vue';
import Collection from './views/Collection.vue';
import CollectionShow from './views/CollectionShow.vue';
import CollectionShowWorkflow from './views/CollectionShowWorkflow.vue';
import CollectionBulk from './views/CollectionBulk.vue';
import Pipelines from './views/Pipelines.vue';
import PipelineList from './views/PipelineList.vue';
import Pipeline from './views/Pipeline.vue';
Vue.use(Router);
export default new Router({
mode: 'hash',
base: import.meta.env.BASE_URL,
routes: [
{
path: '*',
redirect: '/',
},
{
path: '/',
name: 'home',
redirect: '/collections',
},
{
path: '/collections',
component: Collections,
children: [
{
path: '',
name: 'collections',
component: CollectionList,
},
{
path: '/collections/bulk',
name: 'collection-bulk',
component: CollectionBulk,
},
{
path: '/collections/:id',
component: Collection,
children: [
{
path: '/collections/:id',
name: 'collection',
component: CollectionShow,
},
{
path: '/collections/:id/workflow',
name: 'collection-workflow',
component: CollectionShowWorkflow,
},
],
},
],
},
{
path: '/pipelines',
component: Pipelines,
children: [
{
path: '',
name: 'pipelines',
component: PipelineList,
},
{
path: '/pipelines/:id',
name: 'pipeline',
component: Pipeline,
},
],
},
{
path: '/batch',
component: Batch,
children: [
{
path: '',
name: 'batch',
component: Batch,
},
],
},
],
});