';
- echo __('Edit or delete groups can cause problems with synchronization');
- echo '
';
+ html_print_div(
+ [
+ 'class' => 'notify',
+ 'content' => __('Edit or delete groups can cause problems with synchronization'),
+ ]
+ );
} else {
- ui_print_page_header(
+ // Header.
+ ui_print_standard_header(
$title,
'images/group.png',
false,
'',
- true,
- $buttons
+ false,
+ $buttons,
+ [
+ [
+ 'link' => '',
+ 'label' => __('Profiles'),
+ ],
+ [
+ 'link' => '',
+ 'label' => __('Manage agents group'),
+ ],
+ ]
);
}
@@ -471,7 +487,7 @@ if ($update_group) {
$values = [
'nombre' => $name,
'icon' => empty($icon) ? '' : substr($icon, 0, -4),
- 'parent' => $id_parent == -1 ? 0 : $id_parent,
+ 'parent' => ($id_parent == -1) ? 0 : $id_parent,
'disabled' => !$alerts_enabled,
'custom_id' => $custom_id,
'id_skin' => $skin,
diff --git a/pandora_console/godmode/module_library/module_library_view.php b/pandora_console/godmode/module_library/module_library_view.php
index f69c7779fb..31553a5352 100644
--- a/pandora_console/godmode/module_library/module_library_view.php
+++ b/pandora_console/godmode/module_library/module_library_view.php
@@ -58,12 +58,27 @@ $buttons['view'] = [
$tab = get_parameter('tab', 'view');
-if ($tab != 'search_module') {
+if ($tab !== 'search_module') {
$buttons[$tab]['active'] = true;
}
-ui_print_page_header(__('Module Library').' » '.__('View'), '', false, 'module_library', true, $buttons);
+$headerTitle = ($tab === 'categories') ? __('Categories') : __('Main view');
+// Header.
+ui_print_standard_header(
+ $headerTitle,
+ '',
+ false,
+ 'module_library',
+ true,
+ $buttons,
+ [
+ [
+ 'link' => '',
+ 'label' => __('Module library'),
+ ],
+ ]
+);
// Styles.
ui_require_css_file('module_library');
diff --git a/pandora_console/godmode/reporting/graph_builder.php b/pandora_console/godmode/reporting/graph_builder.php
index 27cbc9354d..c891f66cad 100644
--- a/pandora_console/godmode/reporting/graph_builder.php
+++ b/pandora_console/godmode/reporting/graph_builder.php
@@ -26,10 +26,9 @@
* ============================================================================
*/
+// Begin.
global $config;
-
-
if (is_ajax()) {
$search_agents = (bool) get_parameter('search_agents');
@@ -340,37 +339,43 @@ if ($edit_graph) {
$head = __('Graph builder');
-if (isset($name)) {
- $head .= ' - '.$name;
+if (isset($name) === true) {
+ $head .= ' » '.$name;
}
// Header.
-$tab = get_parameter('tab', '');
+$tab = get_parameter('tab');
switch ($tab) {
- default:
- case 'main':
- ui_print_page_header(
- $head,
- 'images/chart.png',
- false,
- 'graph_builder',
- false,
- $buttons
- );
+ case 'graph_editor':
+ $headerHelp = '';
break;
- case 'graph_editor':
- ui_print_page_header(
- $head,
- 'images/chart.png',
- false,
- '',
- false,
- $buttons
- );
+ case 'main':
+ default:
+ $headerHelp = 'graph_builder';
break;
}
+// Header.
+ui_print_standard_header(
+ $head,
+ 'images/chart.png',
+ false,
+ $headerHelp,
+ false,
+ [$buttons],
+ [
+ [
+ 'link' => '',
+ 'label' => __('Reporting'),
+ ],
+ [
+ 'link' => '',
+ 'label' => __('Custom graphs'),
+ ],
+ ]
+);
+
if ($add_graph) {
ui_print_result_message(
$id_graph,
@@ -418,7 +423,8 @@ if (!$delete_module) {
$chunk1 = explode('|', $chunkdata);
$modules = '';
$weights = '';
- for ($a = 0; $a < count($chunk1); $a++) {
+ $chunkCount = count($chunk1);
+ for ($a = 0; $a < $chunkCount; $a++) {
$chunk2[$a] = [];
$chunk2[$a] = explode(',', $chunk1[$a]);
if (strpos($modules, $chunk2[$a][1]) == 0) {
@@ -450,4 +456,8 @@ switch ($active_tab) {
case 'graph_editor':
include_once 'godmode/reporting/graph_builder.graph_editor.php';
break;
+
+ default:
+ // Nothing to do.
+ break;
}
diff --git a/pandora_console/godmode/reporting/graph_container.php b/pandora_console/godmode/reporting/graph_container.php
index 0c8e2a58a1..765e93ea60 100644
--- a/pandora_console/godmode/reporting/graph_container.php
+++ b/pandora_console/godmode/reporting/graph_container.php
@@ -1,19 +1,35 @@
',
];
-// Header
-ui_print_page_header(__('Graph container'), '', false, '', false, $buttons);
+
+// Header.
+ui_print_standard_header(
+ __('Graph container'),
+ '',
+ false,
+ '',
+ false,
+ $buttons,
+ [
+ [
+ 'link' => '',
+ 'label' => __('Reporting'),
+ ],
+ [
+ 'link' => '',
+ 'label' => __('Custom graphs'),
+ ],
+ ]
+);
$container = folder_get_folders();
diff --git a/pandora_console/godmode/reporting/graphs.php b/pandora_console/godmode/reporting/graphs.php
index 3fdf7b3969..0c93074a2d 100644
--- a/pandora_console/godmode/reporting/graphs.php
+++ b/pandora_console/godmode/reporting/graphs.php
@@ -1,16 +1,32 @@
'',
+ 'label' => __('Reporting'),
+ ],
+ [
+ 'link' => '',
+ 'label' => __('Custom graphs'),
+ ],
+ ]
+);
// Delete module SQL code
if ($delete_graph) {
diff --git a/pandora_console/godmode/reporting/map_builder.php b/pandora_console/godmode/reporting/map_builder.php
index 1dd607c57c..b0a8803336 100644
--- a/pandora_console/godmode/reporting/map_builder.php
+++ b/pandora_console/godmode/reporting/map_builder.php
@@ -1,16 +1,32 @@
'',
+ 'label' => __('Topology maps'),
+ ],
+ [
+ 'link' => '',
+ 'label' => __('Visual console'),
+ ],
+ ]
);
} else {
ui_meta_print_header(
diff --git a/pandora_console/godmode/reporting/reporting_builder.php b/pandora_console/godmode/reporting/reporting_builder.php
index d96d239417..cb7181d182 100755
--- a/pandora_console/godmode/reporting/reporting_builder.php
+++ b/pandora_console/godmode/reporting/reporting_builder.php
@@ -567,17 +567,24 @@ switch ($action) {
// Print header.
ui_meta_print_header(__('Reporting'), '', $buttons);
} else {
- // Page header for normal console.
- ui_print_page_header(
- __('Custom reporting'),
+ // Header.
+ ui_print_standard_header(
+ __('List of reports'),
'images/op_reporting.png',
false,
'',
false,
$buttons,
- false,
- '',
- 60
+ [
+ [
+ 'link' => '',
+ 'label' => __('Reporting'),
+ ],
+ [
+ 'link' => '',
+ 'label' => __('Custom reports'),
+ ],
+ ]
);
}
@@ -2486,7 +2493,7 @@ switch ($action) {
0
);
$values['exception_condition'] = (int) get_parameter(
- 'radiobutton_exception_condition',
+ 'exception_condition',
0
);
$values['exception_condition_value'] = get_parameter(
@@ -3145,17 +3152,24 @@ switch ($action) {
// Print header.
ui_meta_print_header(__('Reporting'), '', $buttons);
} else {
- // Page header for normal console.
- ui_print_page_header(
+ // Header.
+ ui_print_standard_header(
$subsection,
'images/op_reporting.png',
false,
'',
false,
$buttons,
- false,
- '',
- 60
+ [
+ [
+ 'link' => '',
+ 'label' => __('Reporting'),
+ ],
+ [
+ 'link' => '',
+ 'label' => __('Custom reports'),
+ ],
+ ]
);
}
@@ -3251,17 +3265,25 @@ if ($enterpriseEnable && defined('METACONSOLE')) {
} else {
$tab_builder = ($activeTab === 'item_editor') ? 'reporting_item_editor_tab' : '';
- if ($action !== 'update' && !is_metaconsole()) {
- ui_print_page_header(
+ if ($action !== 'update' && is_metaconsole() === false) {
+ // Header.
+ ui_print_standard_header(
$textReportName,
'images/op_reporting.png',
false,
$tab_builder,
false,
$buttons,
- false,
- '',
- 60
+ [
+ [
+ 'link' => '',
+ 'label' => __('Reporting'),
+ ],
+ [
+ 'link' => '',
+ 'label' => __('Custom reports'),
+ ],
+ ]
);
}
}
@@ -3291,17 +3313,25 @@ if ($resultOperationDB !== null) {
$activeTab = 'list_items';
$buttons[$activeTab]['active'] = true;
- if (!is_metaconsole()) {
- ui_print_page_header(
+ if (is_metaconsole() === false) {
+ // Header.
+ ui_print_standard_header(
$textReportName,
'images/op_reporting.png',
false,
$helpers,
false,
$buttons,
- false,
- '',
- 60
+ [
+ [
+ 'link' => '',
+ 'label' => __('Reporting'),
+ ],
+ [
+ 'link' => '',
+ 'label' => __('Custom reports'),
+ ],
+ ]
);
}
}
diff --git a/pandora_console/godmode/reporting/visual_console_builder.php b/pandora_console/godmode/reporting/visual_console_builder.php
index 4bbd818c62..23ff0e5889 100755
--- a/pandora_console/godmode/reporting/visual_console_builder.php
+++ b/pandora_console/godmode/reporting/visual_console_builder.php
@@ -1,16 +1,33 @@
'',
+ 'label' => __('Topology maps'),
+ ],
+ [
+ 'link' => '',
+ 'label' => __('Visual console'),
+ ],
+ ]
);
}
diff --git a/pandora_console/godmode/reporting/visual_console_favorite.php b/pandora_console/godmode/reporting/visual_console_favorite.php
index 8bd58abf64..16b5978dd2 100644
--- a/pandora_console/godmode/reporting/visual_console_favorite.php
+++ b/pandora_console/godmode/reporting/visual_console_favorite.php
@@ -1,19 +1,38 @@
'',
+ 'label' => __('Topology maps'),
+ ],
+ [
+ 'link' => '',
+ 'label' => __('Visual console'),
+ ],
+ ]
);
} else {
ui_meta_print_header(
diff --git a/pandora_console/godmode/setup/os.php b/pandora_console/godmode/setup/os.php
index 44888465bf..1be6755749 100644
--- a/pandora_console/godmode/setup/os.php
+++ b/pandora_console/godmode/setup/os.php
@@ -1,17 +1,32 @@
'',
+ 'label' => __('Servers'),
+ ],
+ [
+ 'link' => '',
+ 'label' => __('Edit OS'),
+ ],
+ ]
+ );
}
-if (!empty($id_message)) {
+if (empty($id_message) === false) {
switch ($id_message) {
case 1:
echo ui_print_success_message(__('Success creating OS'), '', true);
@@ -226,13 +260,11 @@ if (!empty($id_message)) {
switch ($tab) {
case 'list':
+ default:
include_once $config['homedir'].'/godmode/setup/os.list.php';
- return;
+ break;
- break;
case 'builder':
include_once $config['homedir'].'/godmode/setup/os.builder.php';
- return;
-
- break;
+ break;
}
diff --git a/pandora_console/godmode/snmpconsole/snmp_alert.php b/pandora_console/godmode/snmpconsole/snmp_alert.php
index f806096ea9..0dc5f20a8e 100755
--- a/pandora_console/godmode/snmpconsole/snmp_alert.php
+++ b/pandora_console/godmode/snmpconsole/snmp_alert.php
@@ -1257,7 +1257,14 @@ if ($create_alert || $update_alert) {
foreach ($other_actions as $action) {
$data[1] .= '';
html_print_input_hidden('multiple_delete', 1);
- html_print_submit_button(__('Delete selected'), 'delete_button', false, 'class="sub delete"');
+ html_print_submit_button(__('Delete selected'), 'delete_button', false, 'class="sub delete mrgn_btn_10px"');
echo '
';
echo '';
}
diff --git a/pandora_console/godmode/snmpconsole/snmp_filters.php b/pandora_console/godmode/snmpconsole/snmp_filters.php
index 8afefcf34f..821d7a7c6e 100644
--- a/pandora_console/godmode/snmpconsole/snmp_filters.php
+++ b/pandora_console/godmode/snmpconsole/snmp_filters.php
@@ -32,15 +32,36 @@ $index_post = (int) get_parameter('index_post', 0);
// Create/update header
if ($edit_filter > -2) {
if ($edit_filter > -1) {
- ui_print_page_header(__('SNMP Console').' » '.__('Update filter'), 'images/op_snmp.png', false, '', false);
+ $activeFilterCaption = ' » '.__('Update filter');
} else {
- ui_print_page_header(__('SNMP Console').' » '.__('Create filter'), 'images/op_snmp.png', false, '', false);
+ $activeFilterCaption = ' » '.__('Create filter');
}
} else {
// Overview header
- ui_print_page_header(__('SNMP Console').' » '.__('Filter overview'), 'images/op_snmp.png', false, '', false);
+ $activeFilterCaption = ' » '.__('Filter overview');
}
+// Header.
+ui_print_standard_header(
+ __('SNMP Console').$activeFilterCaption,
+ 'images/op_snmp.png',
+ false,
+ '',
+ false,
+ [],
+ [
+ [
+ 'link' => '',
+ 'label' => __('Monitoring'),
+ ],
+ [
+ 'link' => '',
+ 'label' => __('SMNP'),
+ ],
+ ]
+);
+
+
// Create/update filter
if ($update_filter > -2) {
// UPDATE
diff --git a/pandora_console/godmode/snmpconsole/snmp_trap_generator.php b/pandora_console/godmode/snmpconsole/snmp_trap_generator.php
index 29137f1382..15173eee4c 100755
--- a/pandora_console/godmode/snmpconsole/snmp_trap_generator.php
+++ b/pandora_console/godmode/snmpconsole/snmp_trap_generator.php
@@ -33,14 +33,27 @@ $snmp_type = (int) get_parameter('snmp_type', 0);
$snmp_value = (string) get_parameter('snmp_value', '');
$generate_trap = (bool) get_parameter('generate_trap', 0);
-ui_print_page_header(
+// Header.
+ui_print_standard_header(
__('SNMP Trap generator'),
'images/op_snmp.png',
false,
'snmp_trap_generator_view',
- false
+ false,
+ [],
+ [
+ [
+ 'link' => '',
+ 'label' => __('Monitoring'),
+ ],
+ [
+ 'link' => '',
+ 'label' => __('SMNP'),
+ ],
+ ]
);
+
if ($generate_trap) {
$result = true;
$error = '';
diff --git a/pandora_console/include/class/AgentWizard.class.php b/pandora_console/include/class/AgentWizard.class.php
index b72b2985f9..bcc7719c23 100644
--- a/pandora_console/include/class/AgentWizard.class.php
+++ b/pandora_console/include/class/AgentWizard.class.php
@@ -1582,6 +1582,10 @@ class AgentWizard extends HTML
if ($candidate['execution_type'] === 0
|| $candidate['execution_type'] === EXECUTION_TYPE_NETWORK
) {
+ if (substr($candidate['value'], 0, 1) !== '.') {
+ $candidate['value'] = '.'.$candidate['value'];
+ }
+
if ($this->serverType === SERVER_TYPE_ENTERPRISE_SATELLITE) {
$values['id_module'] = MODULE_DATA;
$values['module_interval'] = 1;
@@ -1947,6 +1951,10 @@ class AgentWizard extends HTML
|| $candidate['execution_type'] === EXECUTION_TYPE_NETWORK
) {
if ($this->serverType === SERVER_TYPE_ENTERPRISE_SATELLITE) {
+ if (substr($candidate['value'], 0, 1) !== '.') {
+ $candidate['value'] = '.'.$candidate['value'];
+ }
+
$tmp->module_interval(300);
$tmp->id_modulo(MODULE_DATA);
$tmp->updateConfigurationData(
diff --git a/pandora_console/include/class/AgentsAlerts.class.php b/pandora_console/include/class/AgentsAlerts.class.php
index 6ff84785dc..5e0861ed6c 100644
--- a/pandora_console/include/class/AgentsAlerts.class.php
+++ b/pandora_console/include/class/AgentsAlerts.class.php
@@ -729,37 +729,24 @@ class AgentsAlerts extends HTML
public function loadHeader()
{
if ($this->pure == 0) {
- // Breadcrums.
- $this->setBreadcrum([]);
-
- $this->prepareBreadcrum(
- [
- [
- 'link' => '',
- 'label' => __('Monitoring'),
- 'selected' => false,
- ],
- [
- 'link' => '',
- 'label' => __('Views'),
- 'selected' => true,
- ],
- ],
- true
- );
-
- ui_print_page_header(
+ // Header.
+ ui_print_standard_header(
__('Agents/Alerts'),
'',
false,
'',
- true,
- '',
false,
- '',
- GENERIC_SIZE_TEXT,
- '',
- $this->printHeader(true)
+ [],
+ [
+ [
+ 'link' => '',
+ 'label' => __('Monitoring'),
+ ],
+ [
+ 'link' => '',
+ 'label' => __('Views'),
+ ],
+ ]
);
}
diff --git a/pandora_console/include/class/Tree.class.php b/pandora_console/include/class/Tree.class.php
index dc0dca6df4..6050bffa2e 100644
--- a/pandora_console/include/class/Tree.class.php
+++ b/pandora_console/include/class/Tree.class.php
@@ -279,8 +279,10 @@ class Tree
protected function getTagJoin()
{
- return 'INNER JOIN ttag_module ttm
- ON tam.id_agente_modulo = ttm.id_agente_modulo';
+ return 'INNER JOIN tagente_modulo tam
+ ON ta.id_agente = tam.id_agente
+ INNER JOIN ttag_module ttm
+ ON tam.id_agente_modulo = ttm.id_agente_modulo';
}
@@ -931,11 +933,16 @@ class Tree
$agent_status_filter = $this->getAgentStatusFilter();
$module_search_filter = $this->getModuleSearchFilter();
$module_status_inner = '';
- $module_status_filter = $this->getModuleStatusFilterFromTestado();
- if (!empty($module_status_filter)) {
- $module_status_inner = '
- INNER JOIN tagente_estado tae
- ON tae.id_agente_modulo = tam.id_agente_modulo';
+ $module_search_inner = '';
+ $module_search_filter = '';
+ if (!empty($this->filter['searchModule'])) {
+ $module_search_inner = '
+ INNER JOIN tagente_modulo tam
+ ON ta.id_agente = tam.id_agente
+ INNER JOIN tagente_estado tae
+ ON tae.id_agente_modulo = tam.id_agente_modulo';
+ $module_search_filter = "AND tam.disabled = 0
+ AND tam.nombre LIKE '%%".$this->filter['searchModule']."%%' ".$this->getModuleStatusFilterFromTestado();
}
$sql_model = "SELECT %s FROM
@@ -944,13 +951,11 @@ class Tree
FROM tagente ta
LEFT JOIN tagent_secondary_group tasg
ON ta.id_agente = tasg.id_agent
- INNER JOIN tagente_modulo tam
- ON ta.id_agente = tam.id_agente
$inner_inside
$module_status_inner
$group_inner
+ $module_search_inner
WHERE ta.disabled = 0
- AND tam.disabled = 0
%s
$agent_search_filter
$agent_status_filter
@@ -973,6 +978,7 @@ class Tree
$inner
GROUP BY g
ORDER BY $order_by_final";
+ hd($sql, true);
return $sql;
}
@@ -1020,7 +1026,7 @@ class Tree
$agent_search_filter = $this->getAgentSearchFilter();
$agent_status_filter = $this->getAgentStatusFilter();
$module_search_filter = $this->getModuleSearchFilter();
- $module_status_filter = $this->getModuleStatusFilterFromTestado($this->filter['statusModule']);
+ $module_status_filter = $this->getModuleStatusFilter();
$condition = $this->L2condition;
$condition_inside = $this->L2conditionInside;
diff --git a/pandora_console/include/class/TreeModuleGroup.class.php b/pandora_console/include/class/TreeModuleGroup.class.php
index b5cec41370..9b8d39fd6f 100644
--- a/pandora_console/include/class/TreeModuleGroup.class.php
+++ b/pandora_console/include/class/TreeModuleGroup.class.php
@@ -31,6 +31,8 @@ class TreeModuleGroup extends Tree
'tmg.id_mg AS id',
];
$this->L1inner = 'INNER JOIN tmodule_group tmg ON tmg.id_mg = x2.g';
+ $this->L1innerInside = 'INNER JOIN tagente_modulo tam
+ ON ta.id_agente = tam.id_agente';
$this->L1orderByFinal = 'tmg.name';
$this->L2condition = 'AND tam.id_module_group = '.$this->rootID;
diff --git a/pandora_console/include/class/TreeTag.class.php b/pandora_console/include/class/TreeTag.class.php
index 280d34fa2b..87d05a644b 100644
--- a/pandora_console/include/class/TreeTag.class.php
+++ b/pandora_console/include/class/TreeTag.class.php
@@ -27,6 +27,8 @@ class TreeTag extends Tree
$this->L1fieldName = 'id_tag';
$this->L1fieldNameSql = 'ttm.id_tag';
$this->L1innerInside = '
+ INNER JOIN tagente_modulo tam
+ ON ta.id_agente = tam.id_agente
INNER JOIN ttag_module ttm
ON ttm.id_agente_modulo = tam.id_agente_modulo
';
diff --git a/pandora_console/include/config_process.php b/pandora_console/include/config_process.php
index 430ca593b6..d18146b678 100644
--- a/pandora_console/include/config_process.php
+++ b/pandora_console/include/config_process.php
@@ -20,7 +20,7 @@
/**
* Pandora build version and version
*/
-$build_version = 'PC210527';
+$build_version = 'PC210528';
$pandora_version = 'v7.0NG.754';
// Do not overwrite default timezone set if defined.
diff --git a/pandora_console/include/functions_db.php b/pandora_console/include/functions_db.php
index f7d264d0c4..26a46eae7b 100644
--- a/pandora_console/include/functions_db.php
+++ b/pandora_console/include/functions_db.php
@@ -374,7 +374,7 @@ function db_get_value_filter($field, $table, $filter, $where_join='AND', $search
*
* @param string SQL select statement to execute.
*
- * @return the first value of the first row of a table result from query.
+ * @return mixed the first value of the first row of a table result from query.
*/
function db_get_value_sql($sql, $dbconnection=false)
{
diff --git a/pandora_console/include/functions_reporting.php b/pandora_console/include/functions_reporting.php
index b2d1edb62d..0842cff2bd 100755
--- a/pandora_console/include/functions_reporting.php
+++ b/pandora_console/include/functions_reporting.php
@@ -2711,6 +2711,7 @@ function reporting_exception(
// Metaconsole connection.
$server_name = $exc['server_name'];
if (($config['metaconsole'] == 1) && $server_name != '' && is_metaconsole()) {
+ metaconsole_restore_db();
$connection = metaconsole_get_connection($server_name);
if (metaconsole_load_external_db($connection) != NOERR) {
// ui_print_error_message ("Error connecting to ".$server_name);
diff --git a/pandora_console/include/functions_ui.php b/pandora_console/include/functions_ui.php
index 0d12af41a9..f4d0dff15e 100755
--- a/pandora_console/include/functions_ui.php
+++ b/pandora_console/include/functions_ui.php
@@ -35,6 +35,8 @@ if (isset($config['homedir'])) {
include_once $config['homedir'].'/include/functions_groups.php';
include_once $config['homedir'].'/include/functions_users.php';
include_once $config['homedir'].'/include/functions_html.php';
+ // For standard breadcrumbs.
+ ui_require_css_file('discovery');
}
@@ -4302,6 +4304,99 @@ function ui_get_full_url($url='', $no_proxy=false, $add_name_php_file=false, $me
}
+/**
+ * Generates the Pandora 75x Standard views header.
+ * This function should be the standard for
+ * generating the headers of all PFMS views.
+ *
+ * @param string $title The title of this view.
+ * @param string $icon Icon for show.
+ * @param boolean $return If true, the string with the formed header is returned.
+ * @param string $help String for attach at end a link for help.
+ * @param boolean $godmode If false, it will created like operation mode.
+ * @param array $options Tabs allowed
+ * @param array $breadcrumbs Breadcrumbs with the walk.
+ *
+ * EXAMPLE:
+ * ```
+ * $buttons['option_1'] = [
+ * 'active' => false,
+ * 'text' => '
'',
+ 'label' => __('Monitoring'),
+ ],
+ [
+ 'link' => '',
+ 'label' => __('Views'),
+ ],
+ ]
);
} else {
ui_meta_print_header(__('Alerts view'));
diff --git a/pandora_console/operation/agentes/estado_agente.php b/pandora_console/operation/agentes/estado_agente.php
index 73aaa601ff..377cff3d4d 100644
--- a/pandora_console/operation/agentes/estado_agente.php
+++ b/pandora_console/operation/agentes/estado_agente.php
@@ -1,17 +1,32 @@
$setuptab];
}
-ui_print_page_header(
+// Header.
+ui_print_standard_header(
__('Agent detail'),
'images/agent.png',
false,
'',
false,
- $onheader
+ $onheader,
+ [
+ [
+ 'link' => '',
+ 'label' => __('Monitoring'),
+ ],
+ [
+ 'link' => '',
+ 'label' => __('Views'),
+ ],
+ ]
);
if (!$strict_user) {
diff --git a/pandora_console/operation/agentes/group_view.php b/pandora_console/operation/agentes/group_view.php
index 61dfda1a22..000931ff6b 100644
--- a/pandora_console/operation/agentes/group_view.php
+++ b/pandora_console/operation/agentes/group_view.php
@@ -1,16 +1,32 @@
';
} else {
// $updated_info = __("Updated at realtime");
- $updated_info = '';
+ $updated_info = '';
}
// Header.
-ui_print_page_header(
+ui_print_standard_header(
__('Group view'),
'images/group.png',
false,
'',
false,
- $updated_time
+ (array) $updated_time,
+ [
+ [
+ 'link' => '',
+ 'label' => __('Monitoring'),
+ ],
+ [
+ 'link' => '',
+ 'label' => __('Views'),
+ ],
+ ]
);
$total_agentes = 0;
diff --git a/pandora_console/operation/agentes/interface_view.php b/pandora_console/operation/agentes/interface_view.php
index a24788edd0..4f20c459f3 100644
--- a/pandora_console/operation/agentes/interface_view.php
+++ b/pandora_console/operation/agentes/interface_view.php
@@ -1,18 +1,32 @@
'',
+ 'label' => __('Monitoring'),
+ ],
+ [
+ 'link' => '',
+ 'label' => __('Views'),
+ ],
+ ]
);
}
diff --git a/pandora_console/operation/agentes/pandora_networkmap.editor.php b/pandora_console/operation/agentes/pandora_networkmap.editor.php
index 8f735e72de..5eccda04f8 100644
--- a/pandora_console/operation/agentes/pandora_networkmap.editor.php
+++ b/pandora_console/operation/agentes/pandora_networkmap.editor.php
@@ -1,9 +1,8 @@
'',
+ 'label' => __('Topology maps'),
+ ],
+ [
+ 'link' => '',
+ 'label' => __('Networkmap'),
+ ],
+ ]
);
$id_snmp_l2_recon = db_get_value(
diff --git a/pandora_console/operation/agentes/pandora_networkmap.php b/pandora_console/operation/agentes/pandora_networkmap.php
index 8c8c5ec087..c960a333aa 100644
--- a/pandora_console/operation/agentes/pandora_networkmap.php
+++ b/pandora_console/operation/agentes/pandora_networkmap.php
@@ -1,15 +1,32 @@
'',
+ 'label' => __('Topology maps'),
+ ],
+ [
+ 'link' => '',
+ 'label' => __('Networkmap'),
+ ],
+ ]
);
echo $result_txt;
diff --git a/pandora_console/operation/agentes/status_monitor.php b/pandora_console/operation/agentes/status_monitor.php
index a6811c1856..f7d3c7ea30 100644
--- a/pandora_console/operation/agentes/status_monitor.php
+++ b/pandora_console/operation/agentes/status_monitor.php
@@ -1,17 +1,32 @@
'',
+ 'label' => __('Monitoring'),
+ ],
+ [
+ 'link' => '',
+ 'label' => __('Views'),
+ ],
+ ]
);
if ($section == 'fields') {
diff --git a/pandora_console/operation/agentes/tactical.php b/pandora_console/operation/agentes/tactical.php
index d7f668597e..d82a749a85 100755
--- a/pandora_console/operation/agentes/tactical.php
+++ b/pandora_console/operation/agentes/tactical.php
@@ -1,17 +1,32 @@
';
} else {
// $updated_info = __("Updated at realtime");
- $updated_info = '';
+ $updated_info = '';
}
// Header.
-ui_print_page_header(
+ui_print_standard_header(
__('Tactical view'),
'',
false,
'',
false,
- $updated_time
+ (array) $updated_time,
+ [
+ [
+ 'link' => '',
+ 'label' => __('Monitoring'),
+ ],
+ [
+ 'link' => '',
+ 'label' => __('Views'),
+ ],
+ ]
);
// Currently this function makes loading this page is impossible. Change
diff --git a/pandora_console/operation/dashboard/dashboard.php b/pandora_console/operation/dashboard/dashboard.php
index a3379565b7..348b365e9f 100644
--- a/pandora_console/operation/dashboard/dashboard.php
+++ b/pandora_console/operation/dashboard/dashboard.php
@@ -1,7 +1,6 @@
$value) {
$table->data[$i][0] = '#'.$array_get_incidents[$key][0];
$table->data[$i][1] = '
';
- $table->data[$i][1] .= $array_get_incidents[$key][3];
+ $table->data[$i][1] .= ui_print_truncate_text($array_get_incidents[$key][3], 160, false);
$table->data[$i][1] .= '';
$table->data[$i][2] = $group_incident[$array_get_incidents[$key][8]];
$table->data[$i][3] = $status_incident[$array_get_incidents[$key][6]].' / '.$resolution_incident[$array_get_incidents[$key][12]];
diff --git a/pandora_console/operation/messages/message_edit.php b/pandora_console/operation/messages/message_edit.php
index c2ce7529ec..b1748a6736 100644
--- a/pandora_console/operation/messages/message_edit.php
+++ b/pandora_console/operation/messages/message_edit.php
@@ -1,6 +1,6 @@
'',
+ 'label' => __('Workspace'),
+ ],
+ [
+ 'link' => '',
+ 'label' => __('Messages'),
+ ],
+ ]
);
// Read a message.
@@ -381,4 +391,4 @@ html_print_div(
);
echo '';
-echo $jsOutput;
\ No newline at end of file
+echo $jsOutput;
diff --git a/pandora_console/operation/messages/message_list.php b/pandora_console/operation/messages/message_list.php
index 9b25b9da9c..fe96a811a5 100644
--- a/pandora_console/operation/messages/message_list.php
+++ b/pandora_console/operation/messages/message_list.php
@@ -1,9 +1,8 @@
$active_list,
@@ -67,14 +67,25 @@ $buttons['create_message'] = [
).'',
];
-if (!is_ajax()) {
- ui_print_page_header(
- __('Messages'),
+if (is_ajax() === false) {
+ // Header.
+ ui_print_standard_header(
+ $tabSelectedMessage,
'images/email_mc.png',
false,
'',
false,
- $buttons
+ $buttons,
+ [
+ [
+ 'link' => '',
+ 'label' => __('Workspace'),
+ ],
+ [
+ 'link' => '',
+ 'label' => __('Messages'),
+ ],
+ ]
);
}
@@ -86,7 +97,7 @@ if ($mark_unread) {
if ($delete_msg) {
$id = (int) get_parameter('id');
- if ($show_sent) {
+ if ($show_sent === true) {
$result = messages_delete_message_sent($id);
} else {
$result = messages_delete_message($id);
@@ -104,7 +115,7 @@ if ($multiple_delete) {
$ids = (array) get_parameter('delete_multiple_messages', []);
foreach ($ids as $id) {
- if ($show_sent) {
+ if ($show_sent === true) {
$result = messages_delete_message_sent($id);
} else {
$result = messages_delete_message($id);
@@ -122,7 +133,7 @@ if ($multiple_delete) {
);
}
-if ($show_sent) {
+if ($show_sent === true) {
// Sent view.
$num_messages = messages_get_count_sent($config['id_user']);
if ($num_messages > 0 && !is_ajax()) {
@@ -142,7 +153,7 @@ if ($show_sent) {
}
}
-if (empty($messages)) {
+if (empty($messages) === true) {
ui_print_info_message(
[
'no_close' => true,
@@ -175,7 +186,7 @@ if (empty($messages)) {
$table->head[5] = html_print_checkbox('all_delete_messages', 0, false, true, false);
$table->head[0] = __('Status');
- if ($show_sent) {
+ if ($show_sent === true) {
$table->head[1] = __('Destination');
} else {
$table->head[1] = __('Sender');
@@ -194,7 +205,7 @@ if (empty($messages)) {
$data[0] = '';
if ($message['read'] == 1) {
- if ($show_sent) {
+ if ($show_sent === true) {
$data[0] .= '
';
$data[0] .= html_print_image('images/email_inbox.png', true, ['border' => 0, 'title' => __('Click to read'), 'class' => 'invert_filter']);
$data[0] .= '';
@@ -204,7 +215,7 @@ if (empty($messages)) {
$data[0] .= '';
}
} else {
- if ($show_sent) {
+ if ($show_sent === true) {
$data[0] .= '
';
$data[0] .= html_print_image('images/email_inbox.png', true, ['border' => 0, 'title' => __('Message unread - click to read'), 'class' => 'invert_filter']);
$data[0] .= '';
@@ -215,7 +226,7 @@ if (empty($messages)) {
}
}
- if ($show_sent) {
+ if ($show_sent === true) {
$dest_user = get_user_fullname($message['dest']);
if (!$dest_user) {
$dest_user = $message['dest'];
@@ -231,7 +242,7 @@ if (empty($messages)) {
$data[1] = $orig_user;
}
- if ($show_sent) {
+ if ($show_sent === true) {
$data[2] = '
';
} else {
$data[2] = '';
@@ -252,7 +263,7 @@ if (empty($messages)) {
);
$table->cellclass[][4] = 'action_buttons';
- if ($show_sent) {
+ if ($show_sent === true) {
$data[4] = ''.html_print_image('images/cross.png', true, ['title' => __('Delete'), 'class' => 'invert_filter']).'';
} else {
@@ -264,8 +275,8 @@ if (empty($messages)) {
}
}
-if (!empty($messages)) {
- if ($show_sent) {
+if (empty($messages) === false) {
+ if ($show_sent === true) {
echo '