mirror of
https://github.com/Chocobozzz/PeerTube.git
synced 2025-10-05 10:49:28 +02:00
Use "match" sort when searching videos
This commit is contained in:
parent
7d99a6b857
commit
7cec8fd98c
2 changed files with 6 additions and 1 deletions
|
@ -309,6 +309,10 @@ export class MyVideosComponent extends RestTable<Video> implements OnInit, OnDes
|
||||||
// Override REST table method
|
// Override REST table method
|
||||||
onSearch (search: string) {
|
onSearch (search: string) {
|
||||||
this.search = search
|
this.search = search
|
||||||
|
this.sort = {
|
||||||
|
field: 'match',
|
||||||
|
order: -1
|
||||||
|
}
|
||||||
|
|
||||||
this.onFilter()
|
this.onFilter()
|
||||||
}
|
}
|
||||||
|
|
|
@ -123,7 +123,8 @@ export const SORTABLE_COLUMNS = {
|
||||||
'trending',
|
'trending',
|
||||||
'hot',
|
'hot',
|
||||||
'best',
|
'best',
|
||||||
'localVideoFilesSize'
|
'localVideoFilesSize',
|
||||||
|
'match'
|
||||||
],
|
],
|
||||||
|
|
||||||
// Don't forget to update peertube-search-index with the same values
|
// Don't forget to update peertube-search-index with the same values
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue