diff options
Diffstat (limited to 'client/src/app/+videos/+video-edit')
4 files changed, 12 insertions, 18 deletions
diff --git a/client/src/app/+videos/+video-edit/shared/video-caption-add-modal.component.ts b/client/src/app/+videos/+video-edit/shared/video-caption-add-modal.component.ts index e48d16527..875911b91 100644 --- a/client/src/app/+videos/+video-edit/shared/video-caption-add-modal.component.ts +++ b/client/src/app/+videos/+video-edit/shared/video-caption-add-modal.component.ts | |||
@@ -4,7 +4,7 @@ import { VIDEO_CAPTION_FILE_VALIDATOR, VIDEO_CAPTION_LANGUAGE_VALIDATOR } from ' | |||
4 | import { FormReactive, FormValidatorService } from '@app/shared/shared-forms' | 4 | import { FormReactive, FormValidatorService } from '@app/shared/shared-forms' |
5 | import { VideoCaptionEdit } from '@app/shared/shared-main' | 5 | import { VideoCaptionEdit } from '@app/shared/shared-main' |
6 | import { NgbModal, NgbModalRef } from '@ng-bootstrap/ng-bootstrap' | 6 | import { NgbModal, NgbModalRef } from '@ng-bootstrap/ng-bootstrap' |
7 | import { ServerConfig, VideoConstant } from '@shared/models' | 7 | import { HTMLServerConfig, VideoConstant } from '@shared/models' |
8 | 8 | ||
9 | @Component({ | 9 | @Component({ |
10 | selector: 'my-video-caption-add-modal', | 10 | selector: 'my-video-caption-add-modal', |
@@ -14,7 +14,7 @@ import { ServerConfig, VideoConstant } from '@shared/models' | |||
14 | 14 | ||
15 | export class VideoCaptionAddModalComponent extends FormReactive implements OnInit { | 15 | export class VideoCaptionAddModalComponent extends FormReactive implements OnInit { |
16 | @Input() existingCaptions: string[] | 16 | @Input() existingCaptions: string[] |
17 | @Input() serverConfig: ServerConfig | 17 | @Input() serverConfig: HTMLServerConfig |
18 | 18 | ||
19 | @Output() captionAdded = new EventEmitter<VideoCaptionEdit>() | 19 | @Output() captionAdded = new EventEmitter<VideoCaptionEdit>() |
20 | 20 | ||
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 3d916dbce..52801802b 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 | |||
@@ -22,10 +22,10 @@ import { FormReactiveValidationMessages, FormValidatorService } from '@app/share | |||
22 | import { InstanceService } from '@app/shared/shared-instance' | 22 | import { InstanceService } from '@app/shared/shared-instance' |
23 | import { VideoCaptionEdit, VideoEdit, VideoService } from '@app/shared/shared-main' | 23 | import { VideoCaptionEdit, VideoEdit, VideoService } from '@app/shared/shared-main' |
24 | import { | 24 | import { |
25 | HTMLServerConfig, | ||
25 | LiveVideo, | 26 | LiveVideo, |
26 | RegisterClientFormFieldOptions, | 27 | RegisterClientFormFieldOptions, |
27 | RegisterClientVideoFieldOptions, | 28 | RegisterClientVideoFieldOptions, |
28 | ServerConfig, | ||
29 | VideoConstant, | 29 | VideoConstant, |
30 | VideoDetails, | 30 | VideoDetails, |
31 | VideoPrivacy | 31 | VideoPrivacy |
@@ -84,7 +84,7 @@ export class VideoEditComponent implements OnInit, OnDestroy { | |||
84 | calendarTimezone: string | 84 | calendarTimezone: string |
85 | calendarDateFormat: string | 85 | calendarDateFormat: string |
86 | 86 | ||
87 | serverConfig: ServerConfig | 87 | serverConfig: HTMLServerConfig |
88 | 88 | ||
89 | pluginFields: PluginField[] = [] | 89 | pluginFields: PluginField[] = [] |
90 | 90 | ||
@@ -194,9 +194,8 @@ export class VideoEditComponent implements OnInit, OnDestroy { | |||
194 | } | 194 | } |
195 | }) | 195 | }) |
196 | 196 | ||
197 | this.serverConfig = this.serverService.getTmpConfig() | 197 | |
198 | this.serverService.getConfig() | 198 | this.serverConfig = this.serverService.getHTMLConfig() |
199 | .subscribe(config => this.serverConfig = config) | ||
200 | 199 | ||
201 | this.initialVideoCaptions = this.videoCaptions.map(c => c.language.id) | 200 | this.initialVideoCaptions = this.videoCaptions.map(c => c.language.id) |
202 | 201 | ||
diff --git a/client/src/app/+videos/+video-edit/video-add-components/video-send.ts b/client/src/app/+videos/+video-edit/video-add-components/video-send.ts index 3614499cd..a185892fe 100644 --- a/client/src/app/+videos/+video-edit/video-add-components/video-send.ts +++ b/client/src/app/+videos/+video-edit/video-add-components/video-send.ts | |||
@@ -6,7 +6,7 @@ import { listUserChannels } from '@app/helpers' | |||
6 | import { FormReactive } from '@app/shared/shared-forms' | 6 | import { FormReactive } from '@app/shared/shared-forms' |
7 | import { VideoCaptionEdit, VideoCaptionService, VideoEdit, VideoService } from '@app/shared/shared-main' | 7 | import { VideoCaptionEdit, VideoCaptionService, VideoEdit, VideoService } from '@app/shared/shared-main' |
8 | import { LoadingBarService } from '@ngx-loading-bar/core' | 8 | import { LoadingBarService } from '@ngx-loading-bar/core' |
9 | import { ServerConfig, VideoConstant, VideoPrivacy } from '@shared/models' | 9 | import { HTMLServerConfig, VideoConstant, VideoPrivacy } from '@shared/models' |
10 | 10 | ||
11 | @Directive() | 11 | @Directive() |
12 | // tslint:disable-next-line: directive-class-suffix | 12 | // tslint:disable-next-line: directive-class-suffix |
@@ -28,7 +28,7 @@ export abstract class VideoSend extends FormReactive implements OnInit { | |||
28 | protected serverService: ServerService | 28 | protected serverService: ServerService |
29 | protected videoService: VideoService | 29 | protected videoService: VideoService |
30 | protected videoCaptionService: VideoCaptionService | 30 | protected videoCaptionService: VideoCaptionService |
31 | protected serverConfig: ServerConfig | 31 | protected serverConfig: HTMLServerConfig |
32 | 32 | ||
33 | abstract canDeactivate (): CanComponentDeactivateResult | 33 | abstract canDeactivate (): CanComponentDeactivateResult |
34 | 34 | ||
@@ -41,9 +41,7 @@ export abstract class VideoSend extends FormReactive implements OnInit { | |||
41 | this.firstStepChannelId = this.userVideoChannels[0].id | 41 | this.firstStepChannelId = this.userVideoChannels[0].id |
42 | }) | 42 | }) |
43 | 43 | ||
44 | this.serverConfig = this.serverService.getTmpConfig() | 44 | this.serverConfig = this.serverService.getHTMLConfig() |
45 | this.serverService.getConfig() | ||
46 | .subscribe(config => this.serverConfig = config) | ||
47 | 45 | ||
48 | this.serverService.getVideoPrivacies() | 46 | this.serverService.getVideoPrivacies() |
49 | .subscribe( | 47 | .subscribe( |
diff --git a/client/src/app/+videos/+video-edit/video-add.component.ts b/client/src/app/+videos/+video-edit/video-add.component.ts index d735c936c..8606b8222 100644 --- a/client/src/app/+videos/+video-edit/video-add.component.ts +++ b/client/src/app/+videos/+video-edit/video-add.component.ts | |||
@@ -1,7 +1,7 @@ | |||
1 | import { Component, HostListener, OnInit, ViewChild } from '@angular/core' | 1 | import { Component, HostListener, OnInit, ViewChild } from '@angular/core' |
2 | import { ActivatedRoute, Router } from '@angular/router' | 2 | import { ActivatedRoute, Router } from '@angular/router' |
3 | import { AuthService, AuthUser, CanComponentDeactivate, ServerService } from '@app/core' | 3 | import { AuthService, AuthUser, CanComponentDeactivate, ServerService } from '@app/core' |
4 | import { ServerConfig } from '@shared/models' | 4 | import { HTMLServerConfig } from '@shared/models' |
5 | import { VideoEditType } from './shared/video-edit.type' | 5 | import { VideoEditType } from './shared/video-edit.type' |
6 | import { VideoGoLiveComponent } from './video-add-components/video-go-live.component' | 6 | import { VideoGoLiveComponent } from './video-add-components/video-go-live.component' |
7 | import { VideoImportTorrentComponent } from './video-add-components/video-import-torrent.component' | 7 | import { VideoImportTorrentComponent } from './video-add-components/video-import-torrent.component' |
@@ -26,7 +26,7 @@ export class VideoAddComponent implements OnInit, CanComponentDeactivate { | |||
26 | 26 | ||
27 | activeNav: string | 27 | activeNav: string |
28 | 28 | ||
29 | private serverConfig: ServerConfig | 29 | private serverConfig: HTMLServerConfig |
30 | 30 | ||
31 | constructor ( | 31 | constructor ( |
32 | private auth: AuthService, | 32 | private auth: AuthService, |
@@ -42,10 +42,7 @@ export class VideoAddComponent implements OnInit, CanComponentDeactivate { | |||
42 | ngOnInit () { | 42 | ngOnInit () { |
43 | this.user = this.auth.getUser() | 43 | this.user = this.auth.getUser() |
44 | 44 | ||
45 | this.serverConfig = this.serverService.getTmpConfig() | 45 | this.serverConfig = this.serverService.getHTMLConfig() |
46 | |||
47 | this.serverService.getConfig() | ||
48 | .subscribe(config => this.serverConfig = config) | ||
49 | 46 | ||
50 | this.user = this.auth.getUser() | 47 | this.user = this.auth.getUser() |
51 | 48 | ||