aboutsummaryrefslogtreecommitdiffhomepage
diff options
context:
space:
mode:
authorChocobozzz <me@florianbigard.com>2020-06-26 15:41:35 +0200
committerChocobozzz <me@florianbigard.com>2020-06-26 15:41:35 +0200
commitd8b382912e82a535c8158ee496fe396a84851b4e (patch)
treee0144c4180e83cfa18ebcbc0d07faadbd54d6123
parent7820a54e5e168195e58209a4051dd5ecbbec93cf (diff)
downloadPeerTube-d8b382912e82a535c8158ee496fe396a84851b4e.tar.gz
PeerTube-d8b382912e82a535c8158ee496fe396a84851b4e.tar.zst
PeerTube-d8b382912e82a535c8158ee496fe396a84851b4e.zip
Fix search filter in video reports
-rw-r--r--client/src/app/+admin/moderation/video-abuse-list/video-abuse-list.component.ts7
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