From dedc7abb7beccb0b3a4a4fa4e8ccfef8ceecd5a6 Mon Sep 17 00:00:00 2001 From: Chocobozzz Date: Wed, 4 Sep 2019 15:03:50 +0200 Subject: Fix auto blacklist view --- client/src/app/shared/video-blacklist/video-blacklist.service.ts | 9 +++++---- client/src/app/shared/video/video-miniature.component.html | 2 +- client/src/app/shared/video/video-miniature.component.ts | 2 ++ 3 files changed, 8 insertions(+), 5 deletions(-) (limited to 'client') diff --git a/client/src/app/shared/video-blacklist/video-blacklist.service.ts b/client/src/app/shared/video-blacklist/video-blacklist.service.ts index a9eab9b6f..d65da85fe 100644 --- a/client/src/app/shared/video-blacklist/video-blacklist.service.ts +++ b/client/src/app/shared/video-blacklist/video-blacklist.service.ts @@ -34,7 +34,7 @@ export class VideoBlacklistService { ) } - getAutoBlacklistedAsVideoList (videoPagination: ComponentPagination): Observable<{ videos: Video[], totalVideos: number}> { + getAutoBlacklistedAsVideoList (videoPagination: ComponentPagination): Observable> { const pagination = this.restService.componentPaginationToRestPagination(videoPagination) // prioritize first created since waiting longest @@ -48,9 +48,10 @@ export class VideoBlacklistService { return this.authHttp.get>(VideoBlacklistService.BASE_VIDEOS_URL + 'blacklist', { params }) .pipe( map(res => { - const videos = res.data.map(videoBlacklist => new Video(videoBlacklist.video)) - const totalVideos = res.total - return { videos, totalVideos } + return { + total: res.total, + data: res.data.map(videoBlacklist => new Video(videoBlacklist.video)) + } }), catchError(res => this.restExtractor.handleError(res)) ) diff --git a/client/src/app/shared/video/video-miniature.component.html b/client/src/app/shared/video/video-miniature.component.html index 51ca1393d..5d5691b75 100644 --- a/client/src/app/shared/video/video-miniature.component.html +++ b/client/src/app/shared/video/video-miniature.component.html @@ -31,7 +31,7 @@
{{ video.privacy.label }} - - + - {{ getStateLabel(video) }}
diff --git a/client/src/app/shared/video/video-miniature.component.ts b/client/src/app/shared/video/video-miniature.component.ts index 48475033c..d5c7dfd9b 100644 --- a/client/src/app/shared/video/video-miniature.component.ts +++ b/client/src/app/shared/video/video-miniature.component.ts @@ -95,6 +95,8 @@ export class VideoMiniatureComponent implements OnInit { } getStateLabel (video: Video) { + if (!video.state) return '' + if (video.privacy.id !== VideoPrivacy.PRIVATE && video.state.id === VideoState.PUBLISHED) { return this.i18n('Published') } -- cgit v1.2.3 From 5eb9bde8aa50951c7896d5278d0788dda541c475 Mon Sep 17 00:00:00 2001 From: Chocobozzz Date: Wed, 4 Sep 2019 15:08:56 +0200 Subject: Rename signup steps --- client/src/app/+signup/+register/register.component.html | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'client') diff --git a/client/src/app/+signup/+register/register.component.html b/client/src/app/+signup/+register/register.component.html index d7e47c1a8..e4d647fef 100644 --- a/client/src/app/+signup/+register/register.component.html +++ b/client/src/app/+signup/+register/register.component.html @@ -10,13 +10,13 @@
- + - +