1
0
mirror of https://github.com/Radarr/Radarr.git synced 2026-04-20 21:55:03 -04:00

Inital work on Twitter notifications

This commit is contained in:
Gavin Mogan
2015-03-28 22:30:58 -07:00
committed by Mark McDowall
parent e05365a669
commit 2fbf7a4114
22 changed files with 683 additions and 18 deletions
@@ -13,8 +13,11 @@ var view = Marionette.ItemView.extend({
template : 'Settings/Notifications/Edit/NotificationEditViewTemplate',
ui : {
onDownloadToggle : '.x-on-download',
onUpgradeSection : '.x-on-upgrade',
onDownloadToggle : '.x-on-download',
onUpgradeSection : '.x-on-upgrade',
tags : '.x-tags',
indicator : '.x-indicator',
authorizedNotificationButton : '.AuthorizeNotification'
tags : '.x-tags',
modalBody : '.modal-body',
formTag : '.x-form-tag',
@@ -23,7 +26,8 @@ var view = Marionette.ItemView.extend({
events : {
'click .x-back' : '_back',
'change .x-on-download' : '_onDownloadChanged'
'change .x-on-download' : '_onDownloadChanged',
'click .AuthorizeNotification' : '_onAuthorizeNotification'
},
_deleteView : DeleteView,
@@ -81,7 +85,15 @@ var view = Marionette.ItemView.extend({
} else {
this.ui.onUpgradeSection.hide();
}
}
},
_onAuthorizeNotification : function(e) {
var self = this;
self.ui.indicator.show();
this.model.connectData(this.ui.authorizedNotificationButton.data('value')).always(function(newValues) {
self.ui.indicator.hide();
});
}
});
AsModelBoundView.call(view);