mirror of
https://github.com/lidarr/lidarr.git
synced 2025-07-30 11:48:26 -07:00
code to support import existing series.
This commit is contained in:
parent
fa224cc59c
commit
13aa79d5f9
15 changed files with 175 additions and 109 deletions
42
NzbDrone.Web/_backboneApp/Shared/NotificationModel.js
Normal file
42
NzbDrone.Web/_backboneApp/Shared/NotificationModel.js
Normal file
|
@ -0,0 +1,42 @@
|
|||
/// <reference path="../app.js" />
|
||||
|
||||
NzbDrone.Shared.NotificationCollection = Backbone.Collection.extend({
|
||||
|
||||
model: NzbDrone.Shared.NotificationModel,
|
||||
|
||||
});
|
||||
|
||||
|
||||
NzbDrone.Shared.NotificationModel = Backbone.Model.extend({
|
||||
|
||||
mutators: {
|
||||
pre: function () {
|
||||
return this.get('message').lines().lenght > 1;
|
||||
},
|
||||
iconClass: function () {
|
||||
|
||||
if (this.has('icon')) {
|
||||
return "icon";
|
||||
}
|
||||
|
||||
if (this.get('level') == 'info') {
|
||||
return "icon-info-sign";
|
||||
}
|
||||
else if (this.get('level') == 'success') {
|
||||
return 'icon-ok-sign';
|
||||
}
|
||||
else if (this.get('level') == 'error') {
|
||||
return 'icon-warning-sign';
|
||||
}
|
||||
|
||||
return "";
|
||||
}
|
||||
},
|
||||
|
||||
|
||||
defaults: {
|
||||
"level": "info",
|
||||
"title": "",
|
||||
"message": "",
|
||||
}
|
||||
});
|
Loading…
Add table
Add a link
Reference in a new issue