diff options
author | Chocobozzz <me@florianbigard.com> | 2020-06-26 15:41:35 +0200 |
---|---|---|
committer | Chocobozzz <me@florianbigard.com> | 2020-06-26 15:41:35 +0200 |
commit | d8b382912e82a535c8158ee496fe396a84851b4e (patch) | |
tree | e0144c4180e83cfa18ebcbc0d07faadbd54d6123 /client | |
parent | 7820a54e5e168195e58209a4051dd5ecbbec93cf (diff) | |
download | PeerTube-d8b382912e82a535c8158ee496fe396a84851b4e.tar.gz PeerTube-d8b382912e82a535c8158ee496fe396a84851b4e.tar.zst PeerTube-d8b382912e82a535c8158ee496fe396a84851b4e.zip |
Fix search filter in video reports
Diffstat (limited to 'client')
-rw-r--r-- | client/src/app/+admin/moderation/video-abuse-list/video-abuse-list.component.ts | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/client/src/app/+admin/moderation/video-abuse-list/video-abuse-list.component.ts b/client/src/app/+admin/moderation/video-abuse-list/video-abuse-list.component.ts index b0a655e71..409dd42c7 100644 --- a/client/src/app/+admin/moderation/video-abuse-list/video-abuse-list.component.ts +++ b/client/src/app/+admin/moderation/video-abuse-list/video-abuse-list.component.ts | |||
@@ -196,10 +196,10 @@ export class VideoAbuseListComponent extends RestTable implements OnInit, AfterV | |||
196 | this.initialize() | 196 | this.initialize() |
197 | 197 | ||
198 | this.route.queryParams | 198 | this.route.queryParams |
199 | .pipe(filter(params => params.search !== undefined && params.search !== null)) | ||
200 | .subscribe(params => { | 199 | .subscribe(params => { |
201 | this.search = params.search | 200 | this.search = params.search || '' |
202 | this.setTableFilter(params.search) | 201 | |
202 | this.setTableFilter(this.search) | ||
203 | this.loadData() | 203 | this.loadData() |
204 | }) | 204 | }) |
205 | } | 205 | } |
@@ -229,6 +229,7 @@ export class VideoAbuseListComponent extends RestTable implements OnInit, AfterV | |||
229 | setQueryParams (search: string) { | 229 | setQueryParams (search: string) { |
230 | const queryParams: Params = {} | 230 | const queryParams: Params = {} |
231 | if (search) Object.assign(queryParams, { search }) | 231 | if (search) Object.assign(queryParams, { search }) |
232 | |||
232 | this.router.navigate([ '/admin/moderation/video-abuses/list' ], { queryParams }) | 233 | this.router.navigate([ '/admin/moderation/video-abuses/list' ], { queryParams }) |
233 | } | 234 | } |
234 | 235 | ||