Purdy Add Notifications
This commit is contained in:
parent
8dee1e00e5
commit
ff29ab9150
|
@ -16,7 +16,7 @@ namespace NzbDrone.Core.Notifications.Smtp
|
||||||
|
|
||||||
public override string Name
|
public override string Name
|
||||||
{
|
{
|
||||||
get { return "SMTP"; }
|
get { return "Email"; }
|
||||||
}
|
}
|
||||||
|
|
||||||
public override void OnGrab(string message)
|
public override void OnGrab(string message)
|
||||||
|
|
|
@ -19,6 +19,7 @@
|
||||||
<link href="/series/series.css" rel='stylesheet' type='text/css'/>
|
<link href="/series/series.css" rel='stylesheet' type='text/css'/>
|
||||||
<link href="/series/details.css" rel='stylesheet' type='text/css'/>
|
<link href="/series/details.css" rel='stylesheet' type='text/css'/>
|
||||||
<link href="/content/base.css" rel='stylesheet' type='text/css'/>
|
<link href="/content/base.css" rel='stylesheet' type='text/css'/>
|
||||||
|
<link href="/settings/notifications/notifications.css" rel='stylesheet' type='text/css'/>
|
||||||
</head>
|
</head>
|
||||||
<body>
|
<body>
|
||||||
<div id="in-sub-nav">
|
<div id="in-sub-nav">
|
||||||
|
|
|
@ -1 +1,7 @@
|
||||||
{{name}}
|
<div class="add-notification-item span3">
|
||||||
|
<div class="row">
|
||||||
|
<div class="span3">
|
||||||
|
{{name}}
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</div>
|
|
@ -3,8 +3,8 @@
|
||||||
<h3>Add Notification</h3>
|
<h3>Add Notification</h3>
|
||||||
</div>
|
</div>
|
||||||
<div class="modal-body">
|
<div class="modal-body">
|
||||||
<div class="form-horizontal">
|
<div class="notifications">
|
||||||
<div id="notifications-to-add" class="btn-group"></div>
|
<ul class="items"></ul>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<div class="modal-footer">
|
<div class="modal-footer">
|
||||||
|
|
|
@ -8,8 +8,7 @@ define([
|
||||||
|
|
||||||
NzbDrone.Settings.Notifications.AddItemView = Backbone.Marionette.ItemView.extend({
|
NzbDrone.Settings.Notifications.AddItemView = Backbone.Marionette.ItemView.extend({
|
||||||
template : 'Settings/Notifications/AddItemTemplate',
|
template : 'Settings/Notifications/AddItemTemplate',
|
||||||
tagName : 'button',
|
tagName : 'li',
|
||||||
className: 'btn',
|
|
||||||
|
|
||||||
events: {
|
events: {
|
||||||
'click': 'addNotification'
|
'click': 'addNotification'
|
||||||
|
@ -17,6 +16,7 @@ define([
|
||||||
|
|
||||||
addNotification: function () {
|
addNotification: function () {
|
||||||
this.model.set('id', undefined);
|
this.model.set('id', undefined);
|
||||||
|
this.model.set('name', '');
|
||||||
var view = new NzbDrone.Settings.Notifications.EditView({ model: this.model});
|
var view = new NzbDrone.Settings.Notifications.EditView({ model: this.model});
|
||||||
NzbDrone.modalRegion.show(view);
|
NzbDrone.modalRegion.show(view);
|
||||||
}
|
}
|
||||||
|
@ -24,7 +24,7 @@ define([
|
||||||
|
|
||||||
NzbDrone.Settings.Notifications.AddView = Backbone.Marionette.CompositeView.extend({
|
NzbDrone.Settings.Notifications.AddView = Backbone.Marionette.CompositeView.extend({
|
||||||
itemView : NzbDrone.Settings.Notifications.AddItemView,
|
itemView : NzbDrone.Settings.Notifications.AddItemView,
|
||||||
itemViewContainer : '#notifications-to-add',
|
itemViewContainer : '.notifications .items',
|
||||||
template : 'Settings/Notifications/AddTemplate'
|
template : 'Settings/Notifications/AddTemplate'
|
||||||
});
|
});
|
||||||
});
|
});
|
||||||
|
|
|
@ -0,0 +1,24 @@
|
||||||
|
@import "../../shared/Styles/card.less";
|
||||||
|
|
||||||
|
.add-notification-item {
|
||||||
|
.card;
|
||||||
|
cursor: pointer;
|
||||||
|
font-size: 24px;
|
||||||
|
font-weight: lighter;
|
||||||
|
text-align: center;
|
||||||
|
}
|
||||||
|
|
||||||
|
.notifications {
|
||||||
|
text-align: center;
|
||||||
|
|
||||||
|
.items {
|
||||||
|
list-style-type: none;
|
||||||
|
margin: 0px;
|
||||||
|
|
||||||
|
li {
|
||||||
|
display: inline-block;
|
||||||
|
vertical-align: top;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
Loading…
Reference in New Issue