mirror of
https://github.com/hyperion-project/hyperion.ng.git
synced 2025-03-01 10:33:28 +00:00
Read-Only Configuration-Database support (#1046)
This commit is contained in:
@@ -468,6 +468,11 @@ $(document).ready(function() {
|
||||
$('#leds_custom_updsim').attr("disabled", true);
|
||||
$('#leds_custom_save').attr("disabled", true);
|
||||
}
|
||||
|
||||
if ( window.readOnlyMode )
|
||||
{
|
||||
$('#leds_custom_save').attr('disabled', true);
|
||||
}
|
||||
}
|
||||
}, window.serverConfig.leds);
|
||||
|
||||
@@ -520,7 +525,13 @@ $(document).ready(function() {
|
||||
};
|
||||
|
||||
// change save button state based on validation result
|
||||
conf_editor.validate().length ? $('#btn_submit_controller').attr('disabled', true) : $('#btn_submit_controller').attr('disabled', false);
|
||||
conf_editor.validate().length || window.readOnlyMode ? $('#btn_submit_controller').attr('disabled', true) : $('#btn_submit_controller').attr('disabled', false);
|
||||
|
||||
conf_editor.on('change',function() {
|
||||
window.readOnlyMode ? $('#btn_cl_save').attr('disabled', true) : $('#btn_submit').attr('disabled', false);
|
||||
window.readOnlyMode ? $('#btn_ma_save').attr('disabled', true) : $('#btn_submit').attr('disabled', false);
|
||||
window.readOnlyMode ? $('#leds_custom_save').attr('disabled', true) : $('#btn_submit').attr('disabled', false);
|
||||
});
|
||||
|
||||
// led controller sepecific wizards
|
||||
$('#btn_wiz_holder').html("");
|
||||
|
Reference in New Issue
Block a user