diff --git a/pandora_console/godmode/setup/performance.php b/pandora_console/godmode/setup/performance.php index 9e663e63cc..e51f6ff7a9 100644 --- a/pandora_console/godmode/setup/performance.php +++ b/pandora_console/godmode/setup/performance.php @@ -665,6 +665,20 @@ $table_other->data[12][1] = html_print_input_text( true ); +$table_other->data[13][0] = __('Events response max. execution'); +$table_other->data[13][0] .= ui_print_help_tip( + __('Number of events that will perform the desired action at the same time'), + true +); +$table_other->data[13][1] = html_print_input_text( + 'max_execution_event_response', + $config['max_execution_event_response'], + '', + 5, + 5, + true +); + echo '
'; echo '
'; diff --git a/pandora_console/include/functions_config.php b/pandora_console/include/functions_config.php index 565285471d..714005f821 100644 --- a/pandora_console/include/functions_config.php +++ b/pandora_console/include/functions_config.php @@ -739,6 +739,10 @@ function config_update_config() if (!config_update_value('max_graph_container', get_parameter('max_graph_container'))) { $error_update[] = __('Graph container - Max. Items'); } + + if (!config_update_value('max_execution_event_response', get_parameter('max_execution_event_response'))) { + $error_update[] = __('Max. execution event response'); + } break; case 'vis': @@ -1517,6 +1521,10 @@ function config_process_config() config_update_value('max_graph_container', 10); } + if (!isset($config['max_execution_event_response'])) { + config_update_value('max_execution_event_response', 10); + } + if (!isset($config['max_macro_fields'])) { config_update_value('max_macro_fields', 10); } diff --git a/pandora_console/operation/events/events.build_table.php b/pandora_console/operation/events/events.build_table.php index 8ed0f10eed..a9e319c82a 100644 --- a/pandora_console/operation/events/events.build_table.php +++ b/pandora_console/operation/events/events.build_table.php @@ -983,7 +983,11 @@ if ($group_rep == 2) { html_print_button(__('Execute event response'), 'submit_event_response', false, 'execute_event_response(true);', 'class="sub next"'); echo "'; echo ''; - echo ''; + echo ''; echo ''; } } @@ -1012,7 +1016,7 @@ if ($group_rep == 2) { var total_checked = $(".chk_val:checked").length; // Limit number of events to apply custom responses to for performance reasons - if (total_checked > 10) { + if (total_checked > ) { $('#max_custom_event_resp_msg').show(); return; } @@ -1022,18 +1026,22 @@ if ($group_rep == 2) { $('#response_loading_dialog').show(function() { $(".chk_val").each(function() { - if ($(this).is(":checked")) { - //var server_id = $('#hidden-server_id_'+). event_id = $(this).val(); server_id = $('#hidden-server_id_'+event_id).val(); - - response['target'] = get_response_target(event_id, response_id, server_id); - + response['target'] = get_response_target( + event_id, + response_id, + server_id + ); if (total_checked-1 === counter) end=1; - - show_massive_response_dialog(event_id, response_id, response, counter, end); - + show_massive_response_dialog( + event_id, + response_id, + response, + counter, + end + ); counter++; } }); @@ -1087,4 +1095,3 @@ if ($group_rep == 2) { echo ''; } -