diff options
author | Chocobozzz <me@florianbigard.com> | 2020-11-26 09:30:26 +0100 |
---|---|---|
committer | Chocobozzz <me@florianbigard.com> | 2020-11-26 11:30:18 +0100 |
commit | 0151c41c65e0e3e94288314afe295358b9d698f7 (patch) | |
tree | fe5aba4addbf29154ca4a68d0e3fe7242b978c93 /client/src/app | |
parent | ae48a71d57516b7ae2c4f3f63d237a4c972f0ded (diff) | |
download | PeerTube-0151c41c65e0e3e94288314afe295358b9d698f7.tar.gz PeerTube-0151c41c65e0e3e94288314afe295358b9d698f7.tar.zst PeerTube-0151c41c65e0e3e94288314afe295358b9d698f7.zip |
Do not display wait transcoding checkbox
If this is a live and save replay is not enabled
Diffstat (limited to 'client/src/app')
-rw-r--r-- | client/src/app/+videos/+video-edit/shared/video-edit.component.html | 2 | ||||
-rw-r--r-- | client/src/app/+videos/+video-edit/shared/video-edit.component.ts | 10 |
2 files changed, 11 insertions, 1 deletions
diff --git a/client/src/app/+videos/+video-edit/shared/video-edit.component.html b/client/src/app/+videos/+video-edit/shared/video-edit.component.html index 3a24c4136..bf8b0b267 100644 --- a/client/src/app/+videos/+video-edit/shared/video-edit.component.html +++ b/client/src/app/+videos/+video-edit/shared/video-edit.component.html | |||
@@ -136,7 +136,7 @@ | |||
136 | </ng-template> | 136 | </ng-template> |
137 | </my-peertube-checkbox> | 137 | </my-peertube-checkbox> |
138 | 138 | ||
139 | <my-peertube-checkbox *ngIf="waitTranscodingEnabled" inputName="waitTranscoding" formControlName="waitTranscoding" helpPlacement="bottom-right"> | 139 | <my-peertube-checkbox *ngIf="isWaitTranscodingDisplayed()" inputName="waitTranscoding" formControlName="waitTranscoding" helpPlacement="bottom-right"> |
140 | <ng-template ptTemplate="label"> | 140 | <ng-template ptTemplate="label"> |
141 | <ng-container i18n>Publish after transcoding</ng-container> | 141 | <ng-container i18n>Publish after transcoding</ng-container> |
142 | </ng-template> | 142 | </ng-template> |
diff --git a/client/src/app/+videos/+video-edit/shared/video-edit.component.ts b/client/src/app/+videos/+video-edit/shared/video-edit.component.ts index 26d871e59..de78a18cc 100644 --- a/client/src/app/+videos/+video-edit/shared/video-edit.component.ts +++ b/client/src/app/+videos/+video-edit/shared/video-edit.component.ts | |||
@@ -102,6 +102,16 @@ export class VideoEditComponent implements OnInit, OnDestroy { | |||
102 | .map(c => c.language.id) | 102 | .map(c => c.language.id) |
103 | } | 103 | } |
104 | 104 | ||
105 | isWaitTranscodingDisplayed () { | ||
106 | if (!this.waitTranscodingEnabled) return false | ||
107 | |||
108 | if (this.liveVideo) { | ||
109 | return this.form.value['saveReplay'] === true | ||
110 | } | ||
111 | |||
112 | return true | ||
113 | } | ||
114 | |||
105 | updateForm () { | 115 | updateForm () { |
106 | const defaultValues: any = { | 116 | const defaultValues: any = { |
107 | nsfw: 'false', | 117 | nsfw: 'false', |