mirror of
https://github.com/lidarr/lidarr.git
synced 2025-07-31 04:00:18 -07:00
Added seasons to top of series details (toggling and jump to)
This commit is contained in:
parent
49c5762c6d
commit
125deb3931
9 changed files with 176 additions and 5 deletions
31
UI/Series/Details/SeasonMenu/CollectionView.js
Normal file
31
UI/Series/Details/SeasonMenu/CollectionView.js
Normal file
|
@ -0,0 +1,31 @@
|
|||
'use strict';
|
||||
define(
|
||||
[
|
||||
'marionette',
|
||||
'Series/Details/SeasonMenu/ItemView'
|
||||
], function (Marionette, ItemView) {
|
||||
return Marionette.CollectionView.extend({
|
||||
|
||||
itemView: ItemView,
|
||||
|
||||
initialize: function (options) {
|
||||
|
||||
if (!options.episodeCollection) {
|
||||
throw 'episodeCollection is needed';
|
||||
}
|
||||
|
||||
this.episodeCollection = options.episodeCollection;
|
||||
},
|
||||
|
||||
itemViewOptions: function () {
|
||||
return {
|
||||
episodeCollection: this.episodeCollection,
|
||||
};
|
||||
},
|
||||
|
||||
appendHtml: function(collectionView, itemView, index){
|
||||
var childrenContainer = $(collectionView.childrenContainer || collectionView.el);
|
||||
childrenContainer.prepend(itemView.el);
|
||||
}
|
||||
});
|
||||
});
|
Loading…
Add table
Add a link
Reference in a new issue