Merge branch 'ent-7032-boton-ok-wizard-snmp-interfaces' into 'develop'
Hide OK button meanwhile is loading data Closes pandora_enterprise#7032 See merge request artica/pandorafms!3837
This commit is contained in:
commit
8a0b4fd090
|
@ -5343,6 +5343,7 @@ class AgentWizard extends HTML
|
|||
function processListModules() {
|
||||
confirmDialog({
|
||||
title: "<?php echo __('Modules about to be created'); ?>",
|
||||
hideOkButton: true,
|
||||
message: function() {
|
||||
var id = "div-" + uniqId();
|
||||
var loading = "<?php echo __('Loading, this operation might take several minutes...'); ?>";
|
||||
|
@ -5381,6 +5382,8 @@ class AgentWizard extends HTML
|
|||
},
|
||||
datatype: "html",
|
||||
success: function(data) {
|
||||
// Show hidden OK button
|
||||
$('.sub.ok.submit-next').removeClass('invisible_important');
|
||||
$('#' + id).empty().append(data);
|
||||
},
|
||||
error: function(e) {
|
||||
|
|
|
@ -406,6 +406,7 @@ function load_modal(settings) {
|
|||
// eslint-disable-next-line no-unused-vars
|
||||
function confirmDialog(settings) {
|
||||
var randomStr = uniqId();
|
||||
var hideOkButton = "";
|
||||
|
||||
if (settings.size == undefined) {
|
||||
settings.size = 350;
|
||||
|
@ -414,6 +415,10 @@ function confirmDialog(settings) {
|
|||
if (settings.maxHeight == undefined) {
|
||||
settings.maxHeight = 1000;
|
||||
}
|
||||
// You can hide the OK button.
|
||||
if (settings.hideOkButton != undefined) {
|
||||
hideOkButton = "invisible_important ";
|
||||
}
|
||||
|
||||
if (typeof settings.message == "function") {
|
||||
$("body").append(
|
||||
|
@ -447,6 +452,7 @@ function confirmDialog(settings) {
|
|||
{
|
||||
text: "Ok",
|
||||
class:
|
||||
hideOkButton +
|
||||
"ui-widget ui-state-default ui-corner-all ui-button-text-only sub ok submit-next",
|
||||
click: function() {
|
||||
$(this).dialog("close");
|
||||
|
|
|
@ -704,6 +704,9 @@ select:-internal-list-box {
|
|||
.invisible {
|
||||
display: none;
|
||||
}
|
||||
.invisible_important {
|
||||
display: none !important;
|
||||
}
|
||||
|
||||
.visible {
|
||||
display: block;
|
||||
|
|
Loading…
Reference in New Issue