Allow custom redirect uri with Facebook notifier

This commit is contained in:
JonnyWong16 2016-01-23 08:12:41 -08:00
commit b24e9a2185
4 changed files with 29 additions and 33 deletions

View file

@ -136,14 +136,14 @@ from plexpy import helpers
cache: false,
async: true,
complete: function (xhr, status) {
$("#notification-config-modal").html(xhr.responseText);
$('#notification-config-modal').html(xhr.responseText);
}
});
}
$('#osxnotifyregister').click(function () {
var osx_notify_app = $("#osx_notify_app").val();
$.get("/osxnotifyregister", { 'app': osx_notify_app }, function (data) { showMsg("<i class='fa fa-check'></i> " + data, false, true, 3000); });
var osx_notify_app = $('#osx_notify_app').val();
$.get('/osxnotifyregister', { 'app': osx_notify_app }, function (data) { showMsg('<i class="fa fa-check"></i> ' + data, false, true, 3000); });
})
$('#save-notification-item').click(function () {
@ -163,12 +163,12 @@ from plexpy import helpers
});
$('#twitterStep1').click(function () {
$.get("/twitterStep1", function (data) {window.open(data); })
.done(function () { showMsg("<i class='fa fa-check'></i> Confirm Authorization. Check pop-up blocker if no response.", false, true, 3000); });
$.get('/twitterStep1', function (data) {window.open(data); })
.done(function () { showMsg('<i class="fa fa-check"></i> Confirm Authorization. Check pop-up blocker if no response.', false, true, 3000); });
});
$('#twitterStep2').click(function () {
var twitter_key = $("#twitter_key").val();
$.get("/twitterStep2", { 'key': twitter_key }, function (data) { showMsg("<i class='fa fa-check'></i> " + data, false, true, 3000); });
var twitter_key = $('#twitter_key').val();
$.get('/twitterStep2', { 'key': twitter_key }, function (data) { showMsg('<i class="fa fa-check"></i> ' + data, false, true, 3000); });
});
function disableFacebookRequest() {
@ -182,8 +182,8 @@ from plexpy import helpers
$('#facebookStep1').click(function () {
doAjaxCall('set_notification_config', $(this), 'tabs', true);
$.get("/facebookStep1", function (data) {window.open(data); })
.done(function () { showMsg("<i class='fa fa-check'></i> Confirm Authorization. Check pop-up blocker if no response.", false, true, 3000); });
$.get('/facebookStep1', function (data) { window.open(data); })
.done(function () { showMsg('<i class="fa fa-check"></i> Confirm Authorization. Check pop-up blocker if no response.', false, true, 3000); });
});
$('#test_notifier').click(function () {
@ -215,10 +215,10 @@ from plexpy import helpers
// Never send checkbox values directly, always substitute value in hidden input.
$('.checkboxes').click(function () {
var configToggle = $(this).data('id');
if ($(this).is(":checked")) {
$("#"+configToggle).val(1);
if ($(this).is(':checked')) {
$('#'+configToggle).val(1);
} else {
$("#"+configToggle).val(0);
$('#'+configToggle).val(0);
}
});
</script>