diff options
Diffstat (limited to 'client/src/app/+admin/moderation/video-block-list')
-rw-r--r-- | client/src/app/+admin/moderation/video-block-list/video-block-list.component.html | 2 | ||||
-rw-r--r-- | client/src/app/+admin/moderation/video-block-list/video-block-list.component.ts | 19 |
2 files changed, 7 insertions, 14 deletions
diff --git a/client/src/app/+admin/moderation/video-block-list/video-block-list.component.html b/client/src/app/+admin/moderation/video-block-list/video-block-list.component.html index 96293ae5e..7250b1368 100644 --- a/client/src/app/+admin/moderation/video-block-list/video-block-list.component.html +++ b/client/src/app/+admin/moderation/video-block-list/video-block-list.component.html | |||
@@ -27,7 +27,7 @@ | |||
27 | </div> | 27 | </div> |
28 | <input | 28 | <input |
29 | type="text" name="table-filter" id="table-filter" i18n-placeholder placeholder="Filter..." | 29 | type="text" name="table-filter" id="table-filter" i18n-placeholder placeholder="Filter..." |
30 | (keyup)="onBlockSearch($event)" | 30 | (keyup)="onSearch($event)" |
31 | > | 31 | > |
32 | <a class="glyphicon glyphicon-remove-sign form-control-feedback form-control-clear" (click)="resetTableFilter()"></a> | 32 | <a class="glyphicon glyphicon-remove-sign form-control-feedback form-control-clear" (click)="resetTableFilter()"></a> |
33 | <span class="sr-only" i18n>Clear filters</span> | 33 | <span class="sr-only" i18n>Clear filters</span> |
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 2b1ef663c..82818547c 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 | |||
@@ -1,5 +1,5 @@ | |||
1 | import { SortMeta } from 'primeng/api' | 1 | import { SortMeta } from 'primeng/api' |
2 | import { filter, switchMap } from 'rxjs/operators' | 2 | import { switchMap } from 'rxjs/operators' |
3 | import { buildVideoLink, buildVideoOrPlaylistEmbed } from 'src/assets/player/utils' | 3 | import { buildVideoLink, buildVideoOrPlaylistEmbed } from 'src/assets/player/utils' |
4 | import { environment } from 'src/environments/environment' | 4 | import { environment } from 'src/environments/environment' |
5 | import { AfterViewInit, Component, OnInit } from '@angular/core' | 5 | import { AfterViewInit, Component, OnInit } from '@angular/core' |
@@ -25,16 +25,16 @@ export class VideoBlockListComponent extends RestTable implements OnInit, AfterV | |||
25 | videoBlocklistActions: DropdownAction<VideoBlacklist>[][] = [] | 25 | videoBlocklistActions: DropdownAction<VideoBlacklist>[][] = [] |
26 | 26 | ||
27 | constructor ( | 27 | constructor ( |
28 | protected route: ActivatedRoute, | ||
29 | protected router: Router, | ||
28 | private notifier: Notifier, | 30 | private notifier: Notifier, |
29 | private serverService: ServerService, | 31 | private serverService: ServerService, |
30 | private confirmService: ConfirmService, | 32 | private confirmService: ConfirmService, |
31 | private videoBlocklistService: VideoBlockService, | 33 | private videoBlocklistService: VideoBlockService, |
32 | private markdownRenderer: MarkdownService, | 34 | private markdownRenderer: MarkdownService, |
33 | private sanitizer: DomSanitizer, | 35 | private sanitizer: DomSanitizer, |
34 | private videoService: VideoService, | 36 | private videoService: VideoService |
35 | private route: ActivatedRoute, | 37 | ) { |
36 | private router: Router | ||
37 | ) { | ||
38 | super() | 38 | super() |
39 | 39 | ||
40 | this.videoBlocklistActions = [ | 40 | this.videoBlocklistActions = [ |
@@ -104,14 +104,7 @@ export class VideoBlockListComponent extends RestTable implements OnInit, AfterV | |||
104 | }) | 104 | }) |
105 | 105 | ||
106 | this.initialize() | 106 | this.initialize() |
107 | 107 | this.listenToSearchChange() | |
108 | this.route.queryParams | ||
109 | .pipe(filter(params => params.search !== undefined && params.search !== null)) | ||
110 | .subscribe(params => { | ||
111 | this.search = params.search | ||
112 | this.setTableFilter(params.search) | ||
113 | this.loadData() | ||
114 | }) | ||
115 | } | 108 | } |
116 | 109 | ||
117 | ngAfterViewInit () { | 110 | ngAfterViewInit () { |