}
}
+ saveSort () {
+ peertubeLocalStorage.setItem(this.getSortLocalStorageKey(), JSON.stringify(this.sort))
+ }
+
loadLazy (event: LazyLoadEvent) {
logger('Load lazy %o.', event)
field: event.sortField
}
+ this.rowsPerPage = event.rows
+
this.pagination = {
start: event.first,
count: this.rowsPerPage
}
+ this.expandedRows = {}
+
this.reloadData()
this.saveSort()
}
- saveSort () {
- peertubeLocalStorage.setItem(this.getSortLocalStorageKey(), JSON.stringify(this.sort))
- }
-
- onPage (event: { first: number, rows: number }) {
- logger('On page %o.', event)
-
- if (this.rowsPerPage !== event.rows) {
- this.rowsPerPage = event.rows
- this.pagination = {
- start: event.first,
- count: this.rowsPerPage
- }
-
- this.reloadData()
- }
-
- this.expandedRows = {}
- }
-
onSearch (search: string) {
this.search = search
this.reloadData()