mirror of
https://github.com/lidarr/lidarr.git
synced 2025-08-20 05:23:31 -07:00
Calendar colouring, upcoming list shows yesterday
Cleaned up series file a bit. Added spoon for common sugar tasks.
This commit is contained in:
parent
14cf5bf3cc
commit
da2c0d1d65
15 changed files with 130 additions and 68 deletions
31
NzbDrone.Backbone/HeaderView.js
Normal file
31
NzbDrone.Backbone/HeaderView.js
Normal file
|
@ -0,0 +1,31 @@
|
|||
define(['app'], function () {
|
||||
NzbDrone.HeaderView = Backbone.Marionette.ItemView.extend({
|
||||
events: {
|
||||
'click #logo': 'onClick'
|
||||
},
|
||||
|
||||
onClick: function (event) {
|
||||
|
||||
event.preventDefault();
|
||||
|
||||
var target = $(event.target);
|
||||
var href = undefined;
|
||||
|
||||
//look down for <a/>
|
||||
href = event.target.getAttribute('href');
|
||||
|
||||
if (href && href.startsWith('http')) {
|
||||
window.location.href = href;
|
||||
} else {
|
||||
NzbDrone.Router.navigate(href, { trigger: true, replace: true });
|
||||
}
|
||||
|
||||
},
|
||||
|
||||
initialize: function () {
|
||||
this.setElement($('#in-nav'));
|
||||
}
|
||||
});
|
||||
|
||||
return new NzbDrone.HeaderView();
|
||||
});
|
Loading…
Add table
Add a link
Reference in a new issue