Merge branch 'develop' into feature/alias_friendly_name

Conflicts:
	pandora_console/include/functions_ui.php
This commit is contained in:
Alejandro Gallardo Escobar 2017-02-21 15:23:44 +01:00
commit 430ae3e201
20 changed files with 47999 additions and 44596 deletions

View File

@ -32,12 +32,12 @@ require_once ("../include/functions_html.php");
$id = get_parameter ('id');
if (! isset($_SESSION[$config['homeurl_static']]['id_usuario'])) {
if (! isset($_SESSION['id_usuario'])) {
session_start();
session_write_close();
}
$user_language = get_user_language ($_SESSION[$config['homeurl_static']]['id_usuario']);
$user_language = get_user_language ($_SESSION['id_usuario']);
if (file_exists ('../include/languages/'.$user_language.'.mo')) {
$l10n = new gettext_reader (new CachedFileReader ('../include/languages/'.$user_language.'.mo'));

View File

@ -1084,7 +1084,7 @@ if ($update_module || $create_module) {
$throw_unknown_events = (bool)get_parameter('throw_unknown_events', false);
//Set the event type that can show.
$disabled_types_event = array(EVENTS_GOING_UNKNOWN => (int)!$throw_unknown_events);
$disabled_types_event = array(EVENTS_GOING_UNKNOWN => (int)$throw_unknown_events);
$disabled_types_event = io_json_mb_encode($disabled_types_event);
$module_macro_names = (array) get_parameter('module_macro_names', array());

View File

@ -394,9 +394,9 @@ $table->style[2] = 'font-weight: bold';
$table->data['selection_mode'][0] = __('Selection mode');
$table->data['selection_mode'][1] = __('Select modules first') . ' ' .
$table->data['selection_mode'][1] = '<span style="width:110px;display:inline-block;">'.__('Select modules first ') . '</span>' .
html_print_radio_button_extended ("selection_mode", 'modules', '', $selection_mode, false, '', 'style="margin-right: 40px;"', true).'<br>';
$table->data['selection_mode'][1] .= __('Select agents first') . ' ' .
$table->data['selection_mode'][1] .= '<span style="width:110px;display:inline-block;">'.__('Select agents first ') . '</span>' .
html_print_radio_button_extended ("selection_mode", 'agents', '', $selection_mode, false, '', 'style="margin-right: 40px;"', true);

View File

@ -237,9 +237,9 @@ $table->data = array ();
$table->data['selection_mode'][0] = __('Selection mode');
$table->data['selection_mode'][1] = __('Select modules first') . ' ' .
$table->data['selection_mode'][1] = '<span style="width:110px;display:inline-block;">'.__('Select modules first ') . '</span>' .
html_print_radio_button_extended ("selection_mode", 'modules', '', $selection_mode, false, '', 'style="margin-right: 40px;"', true).'<br>';
$table->data['selection_mode'][1] .= __('Select agents first') . ' ' .
$table->data['selection_mode'][1] .= '<span style="width:110px;display:inline-block;">'.__('Select agents first ') . '</span>' .
html_print_radio_button_extended ("selection_mode", 'agents', '', $selection_mode, false, '', 'style="margin-right: 40px;"', true);

View File

@ -142,6 +142,7 @@ switch ($action) {
case 'general':
case 'network_interfaces_report':
case 'availability':
case 'event_report_log':
case 'availability_graph':
case 'agent_module':
$get_data_editor = true;
@ -193,7 +194,9 @@ switch ($action) {
$idAgentModule = $item['id_agent_module'];
$idAgent = db_get_value_filter('id_agente', 'tagente_modulo', array('id_agente_modulo' => $idAgentModule));
break;
case 'event_report_log':
$period = $item['period'];
$description = $item['description'];
case 'simple_graph':
$only_avg = isset($style['only_avg']) ? (bool) $style['only_avg'] : true;
$percentil = isset($style['percentil']) ? $config['percentil'] : 0;
@ -569,6 +572,7 @@ switch ($action) {
case 'MTBF':
case 'MTTR':
case 'simple_baseline_graph':
case 'event_report_log':
$label = (isset($style['label'])) ? $style['label'] : '';
break;
default:
@ -632,7 +636,12 @@ You can of course remove the warnings, that's why we include the source and do n
echo '<input type="hidden" id="type" name="type" value="' . $type . '" />';
}
?>
<?php
$text = __('This type of report brings a lot of data loading, it is recommended to use it for scheduled reports and not for real-time view.');
echo '<a id="log_help_tip" style="visibility: hidden;" href="javascript:" class="tip" >' . html_print_image ("images/tip.png", true, array('title' => $text)) . '</a>';
?>
</td>
</tr>
<tr id="row_name" style="" class="datos">
@ -689,7 +698,8 @@ You can of course remove the warnings, that's why we include the source and do n
<tr id="row_period" style="" class="datos">
<td style="font-weight:bold;">
<?php
echo __('Period');
echo __('Time lapse');
ui_print_help_tip(__('This is the range, or period of time over which the report renders the information for this report type. For example, a week means data from a week ago from now. '));
?>
</td>
<td style="">
@ -2534,6 +2544,7 @@ function chooseType() {
$("#row_last_value").hide();
$("#row_filter_search").hide();
$("#row_percentil").hide();
$("#log_help_tip").css("visibility", "hidden");
$("#agents_row").hide();
$("#select_agent_modules").hide();
$("#modules_row").hide();
@ -2556,6 +2567,30 @@ function chooseType() {
$('#agent_autocomplete_events').show();
switch (type) {
case 'event_report_group':
$("#row_description").show();
$("#row_period").show();
$("#row_servers").show();
$("#row_group").show();
$("#row_show_in_two_columns").show();
$("#row_event_filter").show();
$("#row_event_graphs").show();
$("#row_event_graph_by_agent").show();
$("#row_event_graph_by_user").show();
$("#row_event_graph_by_criticity").show();
$("#row_event_graph_by_validated").show();
$("#row_filter_search").show();
break;
case 'event_report_log':
$("#log_help_tip").css("visibility", "visible");
$("#row_description").show();
$("#row_period").show();
$("#row_agent").show();
break;
case 'simple_graph':
$("#row_time_compare_overlapped").show();
$("#row_only_avg").show();

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

View File

@ -6,7 +6,8 @@
.btn.active.focus {
outline: none;
}
#files-table a.file-link span.glyphicon {
#files-table a.file-link span.glyphicon,
#files-table span.file-link span.glyphicon {
vertical-align: middle;
font-size: x-large;
margin-right: 10px;
@ -24,3 +25,47 @@ div.term-container div.terminal {
-moz-border-radius: 4px;
border-radius: 4px;
}
.glyphicon-refresh-animate {
-animation: spin 1s infinite linear;
-webkit-animation: spin2 1s infinite linear;
}
@-webkit-keyframes spin2 {
from {
-webkit-transform: rotate(0deg);
}
to {
-webkit-transform: rotate(360deg);
}
}
@-moz-keyframes spin {
from {
transform: scale(1) rotate(0deg);
}
to {
transform: scale(1) rotate(360deg);
}
}
@-webkit-keyframes spin {
from {
transform: scale(1) rotate(0deg);
}
to {
transform: scale(1) rotate(360deg);
}
}
@-o-keyframes spin {
from {
transform: scale(1) rotate(0deg);
}
to {
transform: scale(1) rotate(360deg);
}
}
@keyframes spin {
from {
transform: scale(1) rotate(0deg);
}
to {
transform: scale(1) rotate(360deg);
}
}

File diff suppressed because it is too large Load Diff

View File

@ -165,6 +165,12 @@ function reporting_make_reporting_data($report = null, $id_report,
$force_width_chart,
$force_height_chart);
break;
case 'event_report_log':
$report['contents'][] =
reporting_log(
$report,
$content);
break;
case 'general':
$report['contents'][] =
reporting_general(

View File

@ -178,6 +178,9 @@ function reporting_html_print_report($report, $mini = false, $report_info = 1) {
case 'availability':
reporting_html_availability($table, $item);
break;
case 'event_report_log':
reporting_html_log($table, $item);
break;
case 'availability_graph':
reporting_html_availability_graph($table, $item);
break;

View File

@ -633,8 +633,6 @@ function reports_get_report_types ($template = false, $not_editor = false) {
}
}
if (!$template) {
$types['agent_configuration'] = array('optgroup' => __('Configuration'),
'name' => __('Agent configuration'));
@ -651,6 +649,11 @@ function reports_get_report_types ($template = false, $not_editor = false) {
$types['netflow_summary'] = array('optgroup' => __('Netflow'),
'name' => __('Netflow summary table'));
}
if ($config['enterprise_installed']) {
$types['event_report_log'] = array('optgroup' => __('Log'),
'name' => __('Log report'));
}
return $types;
}

View File

@ -2413,25 +2413,18 @@ function ui_print_page_header ($title, $icon = "", $return = false, $help = "",
$separator_class = "separator_view";
}
$buffer = '<div id="'.$type2.'" style=""><div id="menu_tab_left">';
$buffer .= '<ul class="mn"><li class="' . $type . '">&nbsp;' . '&nbsp; ';
if(strpos($title, "Monitoring » Services »") != -1){
$title = str_replace("Monitoring » Services » Service Map » ",'',$title);
}
if(empty($alias)){
$buffer .= '<span style="margin-right:10px;">' .
ui_print_truncate_text($title, $numChars);
}else{
$buffer .= '<span style="">' .
'<span title='.$title.'>'.$alias.'</span>';
}
$buffer .= '<span style="margin-right:10px;">';
if (empty($alias)) $buffer .= ui_print_truncate_text($title, $numChars);
else $buffer .= ui_print_truncate_text($alias, $numChars);
if ($modal && !enterprise_installed()){
$buffer .= "
<div id='".$message."' class='publienterprise' title='Community version' style='float: right;margin-top: -2px !important; margin-left: 2px !important;'><img data-title='Enterprise version' class='img_help forced_title' data-use_title_for_force_title='1' src='images/alert_enterprise.png'></div>

View File

@ -168,20 +168,22 @@ function visual_map_editor_print_item_palette($visualConsole_id, $background) {
<div id="label_box_arrow" style="text-align:center;width:120px;height:110px;margin-top:50px;">
<span>Label position</span>
<div class="labelpos" id="labelposup" position="up" style="width:20px;height:20px;margin-top:10px;margin-left:45px;cursor: pointer;"><img src="'.$config['homeurl'].'images/label_up.png" style="height:100%;width:100%;"></div>
<div class="labelpos" id="labelposleft" position="left" style="position:relative;top:-5px;width:20px;height:20px;margin-top:15px;cursor: pointer;"><img src="'.$config['homeurl'].'images/label_left.png" style="height:100%;width:100%;"></div>
<div style="font-weight:bold;width:40px;height:20px;position:relative;margin-left:35px;margin-top:-24px;cursor: default;"><span style="float:left;margin-top:3px;margin-left:5px;">Object</span></div>
<div class="labelpos" id="labelposright" position="right" style="top:2px;width:20px;height:20px;position:relative;margin-left:90px;margin-top:-24px;cursor: pointer;"><img src="'.$config['homeurl'].'images/label_right.png" style="height:100%;width:100%;"></div>
<div class="labelpos" sel="yes" id="labelposdown" position="down" style="width:20px;height:20px;position:relative;margin-left:45px;margin-top:10px;cursor: pointer;"><img src="'.$config['homeurl'].'images/label_down_2.png" style="height:100%;width:100%;"></div>
<div class="labelpos" id="labelposup" position="up" style="width:20px;height:20px;margin-top:10px;margin-left:45px;cursor: pointer;">
'. html_print_image ('images/label_up.png', true, array('style'=>'height:100%;width:100%;')). '
</div>
<div class="labelpos" id="labelposleft" position="left" style="position:relative;top:-5px;width:20px;height:20px;margin-top:15px;cursor: pointer;">
'. html_print_image ('images/label_left.png', true, array('style'=>'height:100%;width:100%;')). '
</div>
<div style="font-weight:bold;width:40px;height:20px;position:relative;margin-left:35px;margin-top:-24px;cursor: default;">
<span style="float:left;margin-top:3px;margin-left:5px;">Object</span>
</div>
<div class="labelpos" id="labelposright" position="right" style="top:2px;width:20px;height:20px;position:relative;margin-left:90px;margin-top:-24px;cursor: pointer;">
'. html_print_image ('images/label_right.png', true, array('style'=>'height:100%;width:100%;')). '
</div>
<div class="labelpos" sel="yes" id="labelposdown" position="down" style="width:20px;height:20px;position:relative;margin-left:45px;margin-top:10px;cursor: pointer;">
'. html_print_image ('images/label_down_2.png', true, array('style'=>'height:100%;width:100%;')). '
</div>
</div>
</td>
<td align="left" style="">' .
html_print_input_text('label', '', '', 20, 200, true) . '</td>';

BIN
pandora_console/include/languages/es.mo Executable file → Normal file

Binary file not shown.

67197
pandora_console/include/languages/es.po Executable file → Normal file

File diff suppressed because it is too large Load Diff

View File

@ -585,12 +585,13 @@ table.event_details td.cell_event_name {
padding-top: 7px;
display: table-cell;
clear: none;
float: none;
padding-left: 0px !important;
padding-right: 0px !important;
width: auto !important;
}
#list_agents td.cell_0 {
width: 45%;
border-top: 0px none;
}
#list_agents td.cell_0>span.tiny>img {
@ -599,12 +600,6 @@ table.event_details td.cell_event_name {
margin-top: -6px;
margin-left: 0px;
}
#list_agents td.cell_5 {
width: 30%;
}
#list_agents td.cell_6 {
width: 25%;
}
#list_agents .cell_2 .ui-table-cell-label,
#list_agents .cell_3 .ui-table-cell-label,

View File

@ -421,12 +421,9 @@ class Agents {
$.each(data.agents, function(key, agent) {
$(\"table#list_agents tbody\")
.append(\"<tr class=''>\" +
\"<th class='head_vertical'></th>\" +
\"<td class='cell_0'>\" + agent[0] + \"</td>\" +
// \"<td class='cell_1'>\" + agent[1] + \"</td>\" +
\"<td class='cell_1'>\" + agent[2] + \"</td>\" +
\"<td class='cell_2'>\" + agent[3] + \"</td>\" +
// \"<td class='cell_4'>\" + agent[4] + \"</td>\" +
\"<td class='cell_3'>\" + agent[5] + \"</td>\" +
\"<td class='cell_4'>\" + agent[6] + \"</td>\" +
\"<td class='cell_5'>\" + agent[7] + \"</td>\" +

View File

@ -41,6 +41,7 @@ $section = (string) get_parameter_get('section');
<title>eHorus client</title>
<link rel="stylesheet" href="../../include/ehorus/css/bootstrap.min.css" type="text/css" />
<link rel="stylesheet" href="../../include/ehorus/css/style.css" type="text/css" />
<link rel="stylesheet" href="../../include/ehorus/css/xterm.css" type="text/css" />
<script type="text/javascript" src="../../include/ehorus/bundle.min.js"></script>
</head>
<body>

View File

@ -132,6 +132,9 @@ if ($view_graph) {
if (check_acl ($config['id_user'], 0, "RW")) {
$options = array(
'graph_list' => array('active' => false,
'text' => '<a href="index.php?sec=reporting&sec2=godmode/reporting/graphs">' .
html_print_image("images/list.png", true, array ("title" => __('Graph list'))) .'</a>'),
'main' => array('active' => false,
'text' => '<a href="index.php?sec=reporting&sec2=godmode/reporting/graph_builder&tab=main&edit_graph=1&id=' . $id_graph . '">' .
html_print_image("images/chart.png", true, array ("title" => __('Main data'))) .'</a>'),
@ -161,10 +164,10 @@ if ($view_graph) {
}
// Header
ui_print_page_header (__('Reporting') . " &raquo; " .
__('Custom graphs') . " - " . $graph['name'],
"images/chart.png", false, "", false, $options);
ui_print_page_header ($graph['name'],
"images/chart.png", false, "", false, $options);
$graph_return = custom_graphs_print($id_graph, $height, $width, $period, $stacked, true, $unixdate, false, 'white',
array(), '', array(), array(), true, true, true, true, 1, false, false, $percentil, false);
if ($graph_return){