Seperate AddArtist, Artist. Refactor NavSearch, Artist Editor. Other

Misc UI Fixes
This commit is contained in:
Qstick 2017-05-28 01:01:20 -04:00
parent 775f96c865
commit 2baa1da4b6
102 changed files with 4382 additions and 61 deletions

View file

@ -0,0 +1,32 @@
var NzbDroneCell = require('./NzbDroneCell');
module.exports = NzbDroneCell.extend({
className : 'artist-status-cell',
render : function() {
this.$el.empty();
var monitored = this.model.get('monitored');
var status = this.model.get('status');
if (status === 'ended') {
this.$el.html('<i class="icon-lidarr-artist-ended grid-icon" title="Ended"></i>');
this._setStatusWeight(3);
}
else if (!monitored) {
this.$el.html('<i class="icon-lidarr-artist-unmonitored grid-icon" title="Not Monitored"></i>');
this._setStatusWeight(2);
}
else {
this.$el.html('<i class="icon-lidarr-artist-continuing grid-icon" title="Continuing"></i>');
this._setStatusWeight(1);
}
return this;
},
_setStatusWeight : function(weight) {
this.model.set('statusWeight', weight, { silent : true });
}
});