parent
49c5762c6d
commit
125deb3931
@ -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);
|
||||
}
|
||||
});
|
||||
});
|
@ -0,0 +1,14 @@
|
||||
{{#if allFilesDownloaded}}
|
||||
<span class="label label-info season-menu-item">
|
||||
{{else}}
|
||||
<span class="label label-white season-menu-item">
|
||||
{{/if}}
|
||||
<i class="x-season-monitored clickable" title="Toggle season monitored status"/>
|
||||
<span class="x-text text" title="Go to season">
|
||||
{{#if_eq seasonNumber compare=0}}
|
||||
Specials
|
||||
{{else}}
|
||||
S{{Pad2 seasonNumber}}
|
||||
{{/if_eq}}
|
||||
</span>
|
||||
</span>
|
Loading…
Reference in new issue