]>
Commit | Line | Data |
---|---|---|
2c22613c | 1 | import { Routes } from '@angular/router' |
67ed6552 C |
2 | import { UserRightGuard } from '@app/core' |
3 | import { UserRight } from '@shared/models' | |
4 | import { DebugComponent } from './debug' | |
5 | import { JobsComponent } from './jobs/jobs.component' | |
6 | import { LogsComponent } from './logs' | |
118626c8 | 7 | import { RunnersRoutes } from './runners' |
2c22613c C |
8 | |
9 | export const SystemRoutes: Routes = [ | |
10 | { | |
11 | path: 'system', | |
2c22613c C |
12 | children: [ |
13 | { | |
14 | path: '', | |
15 | redirectTo: 'jobs', | |
16 | pathMatch: 'full' | |
17 | }, | |
18 | { | |
19 | path: 'jobs', | |
20 | canActivate: [ UserRightGuard ], | |
21 | component: JobsComponent, | |
22 | data: { | |
23 | meta: { | |
24 | userRight: UserRight.MANAGE_JOBS, | |
f29f487e | 25 | title: $localize`Jobs` |
2c22613c C |
26 | } |
27 | } | |
28 | }, | |
29 | { | |
30 | path: 'logs', | |
31 | canActivate: [ UserRightGuard ], | |
32 | component: LogsComponent, | |
33 | data: { | |
34 | meta: { | |
35 | userRight: UserRight.MANAGE_LOGS, | |
f29f487e | 36 | title: $localize`Logs` |
2c22613c C |
37 | } |
38 | } | |
5d79474c C |
39 | }, |
40 | { | |
41 | path: 'debug', | |
42 | canActivate: [ UserRightGuard ], | |
43 | component: DebugComponent, | |
44 | data: { | |
45 | meta: { | |
46 | userRight: UserRight.MANAGE_DEBUG, | |
f29f487e | 47 | title: $localize`Debug` |
5d79474c C |
48 | } |
49 | } | |
118626c8 C |
50 | }, |
51 | ||
52 | ...RunnersRoutes | |
2c22613c C |
53 | ] |
54 | } | |
55 | ] |