]> git.immae.eu Git - github/Chocobozzz/PeerTube.git/blobdiff - client/src/app/videos/videos-routing.module.ts
Client: fix update button displayed on non owned video
[github/Chocobozzz/PeerTube.git] / client / src / app / videos / videos-routing.module.ts
index 766d29d2209fe386b4b9877781411a7079e85e89..70968b4d1d90681142ce34838c23ab40c8cfa91e 100644 (file)
@@ -1,7 +1,7 @@
 import { NgModule } from '@angular/core';
 import { RouterModule, Routes } from '@angular/router';
 
-import { VideoAddComponent } from './video-add';
+import { VideoAddComponent, VideoUpdateComponent } from './video-edit';
 import { VideoListComponent } from './video-list';
 import { VideosComponent } from './videos.component';
 import { VideoWatchComponent } from './video-watch';
@@ -16,7 +16,7 @@ const videosRoutes: Routes = [
         component: VideoListComponent,
         data: {
           meta: {
-            titleSuffix: ' - Videos list'
+            title: 'Videos list'
           }
         }
       },
@@ -25,10 +25,23 @@ const videosRoutes: Routes = [
         component: VideoAddComponent,
         data: {
           meta: {
-            titleSuffix: ' - Add a video'
+            title: 'Add a video'
           }
         }
       },
+      {
+        path: 'edit/:id',
+        component: VideoUpdateComponent,
+        data: {
+          meta: {
+            title: 'Edit a video'
+          }
+        }
+      },
+      {
+        path: ':id',
+        redirectTo: 'watch/:id'
+      },
       {
         path: 'watch/:id',
         component: VideoWatchComponent