aboutsummaryrefslogtreecommitdiffhomepage
path: root/client/src/app/videos
diff options
context:
space:
mode:
authorChocobozzz <me@florianbigard.com>2018-02-22 09:03:45 +0100
committerChocobozzz <me@florianbigard.com>2018-02-22 09:03:45 +0100
commit6221f311de0eb8f2a9e7e4a77b8cb0ecbde6dfcd (patch)
tree895e833221877e5f2c4bf291a7cd1bda05cf8865 /client/src/app/videos
parent9f4183c9b57acd382668d49e86b0001bcd55550f (diff)
downloadPeerTube-6221f311de0eb8f2a9e7e4a77b8cb0ecbde6dfcd.tar.gz
PeerTube-6221f311de0eb8f2a9e7e4a77b8cb0ecbde6dfcd.tar.zst
PeerTube-6221f311de0eb8f2a9e7e4a77b8cb0ecbde6dfcd.zip
Add ability to update another user video
Diffstat (limited to 'client/src/app/videos')
-rw-r--r--client/src/app/videos/+video-edit/video-update.component.ts10
1 files changed, 7 insertions, 3 deletions
diff --git a/client/src/app/videos/+video-edit/video-update.component.ts b/client/src/app/videos/+video-edit/video-update.component.ts
index d97e00a3a..2fc09278c 100644
--- a/client/src/app/videos/+video-edit/video-update.component.ts
+++ b/client/src/app/videos/+video-edit/video-update.component.ts
@@ -53,9 +53,6 @@ export class VideoUpdateComponent extends FormReactive implements OnInit {
53 this.serverService.videoPrivaciesLoaded 53 this.serverService.videoPrivaciesLoaded
54 .subscribe(() => this.videoPrivacies = this.serverService.getVideoPrivacies()) 54 .subscribe(() => this.videoPrivacies = this.serverService.getVideoPrivacies())
55 55
56 populateAsyncUserVideoChannels(this.authService, this.userVideoChannels)
57 .catch(err => console.error('Cannot populate async user video channels.', err))
58
59 const uuid: string = this.route.snapshot.params['uuid'] 56 const uuid: string = this.route.snapshot.params['uuid']
60 this.videoService.getVideo(uuid) 57 this.videoService.getVideo(uuid)
61 .switchMap(video => { 58 .switchMap(video => {
@@ -67,6 +64,13 @@ export class VideoUpdateComponent extends FormReactive implements OnInit {
67 video => { 64 video => {
68 this.video = new VideoEdit(video) 65 this.video = new VideoEdit(video)
69 66
67 this.userVideoChannels = [
68 {
69 id: video.channel.id,
70 label: video.channel.displayName
71 }
72 ]
73
70 // We cannot set private a video that was not private 74 // We cannot set private a video that was not private
71 if (video.privacy !== VideoPrivacy.PRIVATE) { 75 if (video.privacy !== VideoPrivacy.PRIVATE) {
72 const newVideoPrivacies = [] 76 const newVideoPrivacies = []