diff --git a/pandora_console/include/class/AgentsAlerts.class.php b/pandora_console/include/class/AgentsAlerts.class.php
index e397ce92bf..17c559f89c 100644
--- a/pandora_console/include/class/AgentsAlerts.class.php
+++ b/pandora_console/include/class/AgentsAlerts.class.php
@@ -464,7 +464,7 @@ class AgentsAlerts extends HTML
{
global $config;
- $block = 20;
+ $block = 10;
$filter = [
'offset' => (int) $this->offset,
@@ -595,6 +595,16 @@ class AgentsAlerts extends HTML
echo '';
}
+ // Dynamic Size.
+ if ($this->pure == 1) {
+ // Count of templates.
+ $templateCount = count($templates_raw);
+ // Define a dynamic size.
+ $thSize = floor(80 / $templateCount).'%';
+ } else {
+ $thSize = '8%';
+ }
+
foreach ($templates_raw as $temp) {
if (isset($templates[$temp['id']]) && $templates[$temp['id']] == '') {
$ntemplates++;
@@ -609,14 +619,14 @@ class AgentsAlerts extends HTML
$outputLine = html_print_div(
[
'id' => 'line_header_'.$temp['id'],
- 'class' => 'rotate_text_module position_text_module center',
+ 'class' => 'rotate_text_module position_text_module',
'style' => '',
- 'content' => ''.ui_print_truncate_text(io_safe_output($temp['name']), 20).'',
+ 'content' => '
'.ui_print_truncate_text(io_safe_output($temp['name']), 20).'
',
],
true
);
- echo sprintf('', $outputLine);
+ echo sprintf('', $thSize, $outputLine);
}
}
}
@@ -1030,24 +1040,6 @@ class AgentsAlerts extends HTML
mainForm.submit();
});
- //Get max width of name of modules
- max_width = 0;
- $.each($('.th_class_module_r'), function (i, elem) {
- id = $(elem).attr('id').replace('th_module_r_', '');
-
- width = $("#div_module_r_" + id).width();
-
- if (max_width < width) {
- max_width = width;
- }
- });
-
- $.each($('.th_class_module_r'), function (i, elem) {
- id = $(elem).attr('id').replace('th_module_r_', '');
- $("#th_module_r_" + id).height(($("#div_module_r_" + id).width() + 10) + 'px');
- $("#div_module_r_" + id).css('margin-top', (max_width - 20) + 'px');
- $("#div_module_r_" + id).show();
- });
});
function show_alerts_details(id) {
diff --git a/pandora_console/include/styles/agent_alerts.css b/pandora_console/include/styles/agent_alerts.css
index fc5b3e36ce..9793a52639 100644
--- a/pandora_console/include/styles/agent_alerts.css
+++ b/pandora_console/include/styles/agent_alerts.css
@@ -6,26 +6,31 @@
}
.agents_modules_table .next_previous_step {
- width: 25px;
+ width: 0.1%;
}
.agents_modules_table .header_table_principal_cell {
text-align: right !important;
padding-right: 13px;
- min-width: 130px;
- width: 100%;
+ width: 20%;
}
.agents_modules_table .header_table_caption_cell {
- min-width: 70px;
- max-width: 105px;
height: 200px;
}
.agents_modules_table .position_text_module {
- margin: 0 -10px;
+ display: flex;
+ flex-direction: row;
+ align-items: center;
+ justify-content: center;
}
+/* .agents_modules_table .position_text_module div {
+ padding-left: 10px;
+ margin-top: 90px;
+} */
+
#full_screen_refresh_box,
#slc-refresh-rate,
#img-full-screen {