X-Git-Url: https://git.immae.eu/?a=blobdiff_plain;f=client%2Fsrc%2Fapp%2Fvideos%2F%2Bvideo-edit%2Fvideo-add-components%2Fvideo-import-torrent.component.ts;h=4d0b0b08087f7765b927f0a155b5dc31e2fd177e;hb=0c4bacbff53bc732f5a2677d62a6ead7752e2405;hp=307806bb98eb8f0ae6d9c96ab196b3177d8df05e;hpb=457bb213b273a9b206cc5654eb085cede4e916ad;p=github%2FChocobozzz%2FPeerTube.git diff --git a/client/src/app/videos/+video-edit/video-add-components/video-import-torrent.component.ts b/client/src/app/videos/+video-edit/video-add-components/video-import-torrent.component.ts index 307806bb9..4d0b0b080 100644 --- a/client/src/app/videos/+video-edit/video-add-components/video-import-torrent.component.ts +++ b/client/src/app/videos/+video-edit/video-add-components/video-import-torrent.component.ts @@ -72,6 +72,11 @@ export class VideoImportTorrentComponent extends VideoSend implements OnInit, Ca this.importVideo(torrentfile) } + setTorrentFile (files: FileList) { + this.torrentfileInput.nativeElement.files = files + this.fileChange() + } + importVideo (torrentfile?: Blob) { this.isImportingVideo = true @@ -79,6 +84,7 @@ export class VideoImportTorrentComponent extends VideoSend implements OnInit, Ca privacy: this.firstStepPrivacyId, waitTranscoding: false, commentsEnabled: true, + downloadEnabled: true, channelId: this.firstStepChannelId } @@ -93,13 +99,12 @@ export class VideoImportTorrentComponent extends VideoSend implements OnInit, Ca this.video = new VideoEdit(Object.assign(res.video, { commentsEnabled: videoUpdate.commentsEnabled, + downloadEnabled: videoUpdate.downloadEnabled, support: null, thumbnailUrl: null, previewUrl: null })) - this.videoPrivacies = this.videoService.explainedPrivacyLabels(this.videoPrivacies) - this.hydrateFormFromVideo() },