mirror of
https://github.com/hyperion-project/hyperion.ng.git
synced 2025-03-01 10:33:28 +00:00
impl options explanation, uiLock (#343)
* update schemas * update * killed upstream change * min prio is now 100 * reset watchdog regularly * update * fix * update
This commit is contained in:
@@ -1,4 +1,6 @@
|
||||
$(document).ready( function() {
|
||||
var uiLock = false;
|
||||
|
||||
$("#main-nav").hide();
|
||||
$("#loading_overlay").addClass("overlay");
|
||||
loadContentTo("#container_connection_lost","connection_lost");
|
||||
@@ -22,12 +24,6 @@ $(document).ready( function() {
|
||||
parsedServerInfoJSON = event.response;
|
||||
currentVersion = parsedServerInfoJSON.info.hyperion[0].version;
|
||||
cleanCurrentVersion = currentVersion.replace(/\./g, '');
|
||||
|
||||
// ToDo lock config menu and display appropriate message
|
||||
if (! parsedServerInfoJSON.info.hyperion[0].config_writeable)
|
||||
{
|
||||
console.log("ATTENTION config is not writable");
|
||||
}
|
||||
|
||||
if (parsedServerInfoJSON.info.hyperion[0].config_modified)
|
||||
$("#hyperion_reload_notify").fadeIn("fast");
|
||||
@@ -78,7 +74,7 @@ $(document).ready( function() {
|
||||
});
|
||||
}
|
||||
|
||||
if ($("#logmessages").length == 0)
|
||||
if ($("#logmessages").length == 0 && loggingStreamActive)
|
||||
{
|
||||
requestLoggingStop();
|
||||
}
|
||||
@@ -87,6 +83,19 @@ $(document).ready( function() {
|
||||
$("#loading_overlay").removeClass("overlay");
|
||||
$("#main-nav").show('slide', {direction: 'left'}, 1000);
|
||||
|
||||
if (!parsedServerInfoJSON.info.hyperion[0].config_writeable)
|
||||
{
|
||||
showInfoDialog('uilock',$.i18n('InfoDialog_nowrite_title'),$.i18n('InfoDialog_nowrite_text'));
|
||||
$('#wrapper').toggle(false);
|
||||
uiLock = true;
|
||||
}
|
||||
else if (uiLock)
|
||||
{
|
||||
$("#modal_dialog").modal('hide');
|
||||
$('#wrapper').toggle(true);
|
||||
uiLock = false;
|
||||
}
|
||||
|
||||
}); // end cmd-serverinfo
|
||||
|
||||
$(hyperion).one("cmd-config-getschema", function(event) {
|
||||
@@ -108,11 +117,7 @@ $(document).ready( function() {
|
||||
});
|
||||
|
||||
$("#btn_hyperion_reload").on("click", function(){
|
||||
$(hyperion).off();
|
||||
requestServerConfigReload();
|
||||
watchdog = 1;
|
||||
$("#wrapper").fadeOut("slow");
|
||||
cron();
|
||||
initRestart();
|
||||
});
|
||||
});
|
||||
|
||||
|
Reference in New Issue
Block a user