]> git.immae.eu Git - github/Chocobozzz/PeerTube.git/blob - client/src/app/+accounts/accounts-routing.module.ts
Fix typo in db field check
[github/Chocobozzz/PeerTube.git] / client / src / app / +accounts / accounts-routing.module.ts
1 import { NgModule } from '@angular/core'
2 import { RouterModule, Routes } from '@angular/router'
3 import { MetaGuard } from '@ngx-meta/core'
4 import { AccountsComponent } from './accounts.component'
5 import { AccountVideosComponent } from './account-videos/account-videos.component'
6 import { AccountAboutComponent } from './account-about/account-about.component'
7 import { AccountVideoChannelsComponent } from './account-video-channels/account-video-channels.component'
8
9 const accountsRoutes: Routes = [
10 {
11 path: 'peertube',
12 redirectTo: '/videos/local'
13 },
14 {
15 path: ':accountId',
16 component: AccountsComponent,
17 canActivateChild: [ MetaGuard ],
18 children: [
19 {
20 path: '',
21 redirectTo: 'video-channels',
22 pathMatch: 'full'
23 },
24 {
25 path: 'videos',
26 component: AccountVideosComponent,
27 data: {
28 meta: {
29 title: 'Account videos'
30 },
31 reuse: {
32 enabled: true,
33 key: 'account-videos-list'
34 }
35 }
36 },
37 {
38 path: 'video-channels',
39 component: AccountVideoChannelsComponent,
40 data: {
41 meta: {
42 title: 'Account video channels'
43 }
44 }
45 },
46 {
47 path: 'about',
48 component: AccountAboutComponent,
49 data: {
50 meta: {
51 title: 'About account'
52 }
53 }
54 }
55 ]
56 }
57 ]
58
59 @NgModule({
60 imports: [ RouterModule.forChild(accountsRoutes) ],
61 exports: [ RouterModule ]
62 })
63 export class AccountsRoutingModule {}