mirror of
https://github.com/jellyfin/jellyfin-web
synced 2025-03-30 19:56:21 +00:00
added air days filters to the tv shows page
This commit is contained in:
parent
a61f2f4840
commit
2d3d5c2d9b
2 changed files with 45 additions and 0 deletions
|
@ -143,6 +143,22 @@
|
|||
reloadItems(page);
|
||||
});
|
||||
|
||||
$('.chkAirDays', this).on('change', function () {
|
||||
|
||||
var filterName = this.getAttribute('data-filter');
|
||||
var filters = query.AirDays || "";
|
||||
|
||||
filters = (',' + filters).replace(',' + filterName, '').substring(1);
|
||||
|
||||
if (this.checked) {
|
||||
filters = filters ? (filters + ',' + filterName) : filterName;
|
||||
}
|
||||
|
||||
query.AirDays = filters;
|
||||
|
||||
reloadItems(page);
|
||||
});
|
||||
|
||||
}).on('pagebeforeshow', "#tvShowsPage", function () {
|
||||
|
||||
reloadItems(this);
|
||||
|
@ -179,6 +195,15 @@
|
|||
this.checked = filters.indexOf(',' + filterName) != -1;
|
||||
|
||||
}).checkboxradio('refresh');
|
||||
|
||||
$('.chkAirDays', this).each(function () {
|
||||
|
||||
var filters = "," + (query.AirDays || "");
|
||||
var filterName = this.getAttribute('data-filter');
|
||||
|
||||
this.checked = filters.indexOf(',' + filterName) != -1;
|
||||
|
||||
}).checkboxradio('refresh');
|
||||
});
|
||||
|
||||
})(jQuery, document);
|
Loading…
Add table
Add a link
Reference in a new issue