mirror of
https://github.com/jellyfin/jellyfin-web
synced 2025-03-30 19:56:21 +00:00
update collections
This commit is contained in:
parent
69c6074e41
commit
e1e60b6f94
2 changed files with 32 additions and 3 deletions
|
@ -61,6 +61,7 @@
|
|||
limit: query.Limit,
|
||||
totalRecordCount: result.TotalRecordCount,
|
||||
viewButton: false,
|
||||
sortButton: true,
|
||||
showLimit: false,
|
||||
updatePageSizeSetting: false,
|
||||
addLayoutButton: true,
|
||||
|
@ -159,6 +160,36 @@
|
|||
reloadItems(page);
|
||||
});
|
||||
|
||||
// On callback make sure to set StartIndex = 0
|
||||
$('.btnSort', page).on('click', function () {
|
||||
LibraryBrowser.showSortMenu({
|
||||
items: [{
|
||||
name: Globalize.translate('OptionNameSort'),
|
||||
id: 'SortName'
|
||||
},
|
||||
{
|
||||
name: Globalize.translate('OptionImdbRating'),
|
||||
id: 'CommunityRating,SortName'
|
||||
},
|
||||
{
|
||||
name: Globalize.translate('OptionDateAdded'),
|
||||
id: 'DateCreated,SortName'
|
||||
},
|
||||
{
|
||||
name: Globalize.translate('OptionParentalRating'),
|
||||
id: 'OfficialRating,SortName'
|
||||
},
|
||||
{
|
||||
name: Globalize.translate('OptionReleaseDate'),
|
||||
id: 'PremiereDate,SortName'
|
||||
}],
|
||||
callback: function () {
|
||||
reloadItems(page);
|
||||
},
|
||||
query: query
|
||||
});
|
||||
});
|
||||
|
||||
LibraryBrowser.saveQueryValues(getSavedQueryKey(), query);
|
||||
|
||||
Dashboard.hideLoadingMsg();
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue