Revert "Revert "Add proxy warning to dashboard""

This reverts commit 27ae1b3e82.
This commit is contained in:
Garfield69
2019-04-01 15:45:32 +13:00
parent 27ae1b3e82
commit a083090b5e
4 changed files with 36 additions and 7 deletions

View File

@@ -99,6 +99,7 @@ function loadJackettSettings() {
doNotify(value, "danger", "glyphicon glyphicon-alert", false);
})
proxyWarning(data.proxy_url);
reloadIndexers();
});
}
@@ -1221,4 +1222,15 @@ function bindUIButtons() {
doNotify("Request to Jackett server failed", "danger", "glyphicon glyphicon-alert");
});
});
$('#jackett-proxy-url').on('input', function () {
proxyWarning($(this).val());
});
}
function proxyWarning(input) {
if (input.trim() != "")
$('#proxy-warning').show();
else
$('#proxy-warning').hide();
}