From 4ee63ec6487a1e5bc35f539c80364fb3c06b522b Mon Sep 17 00:00:00 2001 From: Rigel Kent Date: Sun, 28 Jun 2020 20:28:59 +0200 Subject: remove extra action for when the video block type is set to manual --- .../moderation/video-block-list/video-block-list.component.ts | 10 ++++++---- 1 file changed, 6 insertions(+), 4 deletions(-) (limited to 'client/src/app') diff --git a/client/src/app/+admin/moderation/video-block-list/video-block-list.component.ts b/client/src/app/+admin/moderation/video-block-list/video-block-list.component.ts index c03f9248e..5a5132527 100644 --- a/client/src/app/+admin/moderation/video-block-list/video-block-list.component.ts +++ b/client/src/app/+admin/moderation/video-block-list/video-block-list.component.ts @@ -39,7 +39,8 @@ export class VideoBlockListComponent extends RestTable implements OnInit, AfterV [ { label: this.i18n('Internal actions'), - isHeader: true + isHeader: true, + isDisplayed: videoBlock => videoBlock.type === VideoBlacklistType.AUTO_BEFORE_PUBLISHED }, { label: this.i18n('Switch video block to manual'), @@ -54,7 +55,8 @@ export class VideoBlockListComponent extends RestTable implements OnInit, AfterV err => this.notifier.error(err.message) ) - } + }, + isDisplayed: videoBlock => videoBlock.type === VideoBlacklistType.AUTO_BEFORE_PUBLISHED } ], [ @@ -63,12 +65,12 @@ export class VideoBlockListComponent extends RestTable implements OnInit, AfterV isHeader: true }, { - label: this.i18n('Unblock video'), + label: this.i18n('Unblock'), handler: videoBlock => this.unblockVideo(videoBlock) }, { - label: this.i18n('Delete video'), + label: this.i18n('Delete'), handler: async videoBlock => { const res = await this.confirmService.confirm( this.i18n('Do you really want to delete this video?'), -- cgit v1.2.3