Merge pull request #532 from b1rdhous3/master

Added Information Box for saving confirmation
This commit is contained in:
Rick164 2019-02-07 12:50:33 +01:00 committed by GitHub
commit 5c7b94b7af
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
5 changed files with 17 additions and 1 deletions

View File

@ -103,7 +103,7 @@
<label class="ltdlabel" for="ip_cl_position" data-i18n="conf_leds_layout_cl_inppos">Input position</label>
</td>
<td class="itd">
<input class="form-control ledCLconstr" id="ip_cl_position" type="number" value="0" step="1">
<input class="form-control ledCLconstr" id="ip_cl_position" type="number" value="0" min="0" step="1">
</td>
</tr>
<tr>

View File

@ -66,6 +66,8 @@
"dashboard_alert_message_confedit" : "Deine Hyperion Konfiguration wurde verändert. Um die Änderungen anzuwenden, starte Hyperion neu.",
"dashboard_alert_message_disabled_t" : "Hyperion deaktiviert",
"dashboard_alert_message_disabled" : "Hyperion ist momentan deaktiviert! Um Hyperion zu nutzen, musst du es zuerst wieder im Dashboard aktivieren.",
"dashboard_alert_message_confsave_success_t" : "Konfiguration gespeichert",
"dashboard_alert_message_confsave_success" : "Deine Hyperion Konfiguration wurde erfolgreich gespeichert. Deine Änderungen sind somit übernommen.",
"main_menu_dashboard_token" : "Dashboard",
"main_menu_configuration_token" : "Konfiguration",
"main_menu_general_conf_token" : "Allgemein",

View File

@ -66,6 +66,8 @@
"dashboard_alert_message_confedit" : "Your Hyperion configuration has been modified. To apply it, restart Hyperion.",
"dashboard_alert_message_disabled_t" : "Hyperion disabled",
"dashboard_alert_message_disabled" : "Hyperion is currently disabled! To use it again, enable it at the dashboard.",
"dashboard_alert_message_confsave_success_t" : "Configuration saved",
"dashboard_alert_message_confsave_success" : "Your Hyperion configuration has been saved successfully. Your changes are now active.",
"main_menu_dashboard_token" : "Dashboard",
"main_menu_configuration_token" : "Configuration",
"main_menu_general_conf_token" : "General",

View File

@ -202,6 +202,12 @@
<p><button id="btn_hyperion_reload" class="btn btn-warning btn-sm" style="margin-top:10px" data-i18n="general_btn_restarthyperion"></button></p>
</div>
</div>
<div id="hyperion_config_write_success_notify" style="display:none;padding:0 10px;margin:0">
<div class="bs-callout bs-callout-success">
<h4 data-i18n="dashboard_alert_message_confsave_success_t"></h4>
<span data-i18n="dashboard_alert_message_confsave_success"></span>
</div>
</div>
<div id="hyperion_disabled_notify" style="display:none;padding:0 10px;margin:0">
<div class="bs-callout bs-callout-danger">
<h4 data-i18n="dashboard_alert_message_disabled_t"></h4>

View File

@ -54,6 +54,12 @@ $(document).ready( function() {
showOptHelp = serverConfig.general.showOptHelp;
});
$(hyperion).on("cmd-config-setconfig", function(event) {
if (event.response.success === true) {
$('#hyperion_config_write_success_notify').fadeIn().delay(5000).fadeOut();
}
});
$(hyperion).on("error",function(event){
showInfoDialog("error","Error", event.reason);