2013-05-30 Miguel de Dios <miguel.dedios@artica.es>
* operation/agentes/networkmap.php: fixed the string of button to refresh the networkmap. Fixes: #2254 git-svn-id: https://svn.code.sf.net/p/pandora/code/trunk@8235 c3f86ba8-e40f-0410-aaad-9ba5e7f4b01f
This commit is contained in:
parent
17274a32c6
commit
c4267df092
|
@ -1,3 +1,10 @@
|
||||||
|
2013-05-30 Miguel de Dios <miguel.dedios@artica.es>
|
||||||
|
|
||||||
|
* operation/agentes/networkmap.php: fixed the string of button to
|
||||||
|
refresh the networkmap.
|
||||||
|
|
||||||
|
Fixes: #2254
|
||||||
|
|
||||||
2013-05-30 Miguel de Dios <miguel.dedios@artica.es>
|
2013-05-30 Miguel de Dios <miguel.dedios@artica.es>
|
||||||
|
|
||||||
* godmode/groups/group_list.php, include/functions_groups.php: fixed
|
* godmode/groups/group_list.php, include/functions_groups.php: fixed
|
||||||
|
|
|
@ -67,7 +67,8 @@ if ($add_networkmap) {
|
||||||
$center = 0;
|
$center = 0;
|
||||||
$name = $activeTab;
|
$name = $activeTab;
|
||||||
$check = db_get_value('name', 'tnetwork_map', 'name', $name);
|
$check = db_get_value('name', 'tnetwork_map', 'name', $name);
|
||||||
$sql = db_get_value_filter('COUNT(name)', 'tnetwork_map', array('name' => "%$name"));
|
$sql = db_get_value_filter('COUNT(name)', 'tnetwork_map',
|
||||||
|
array('name' => "%$name"));
|
||||||
|
|
||||||
if ($check) {
|
if ($check) {
|
||||||
$id_networkmap = networkmap_create_networkmap("($sql) ".$name,
|
$id_networkmap = networkmap_create_networkmap("($sql) ".$name,
|
||||||
|
@ -150,10 +151,6 @@ $nomaps = false;
|
||||||
if ($networkmaps === false) {
|
if ($networkmaps === false) {
|
||||||
$nomaps = true;
|
$nomaps = true;
|
||||||
}
|
}
|
||||||
/*// When is the first map, we create one
|
|
||||||
if($nomaps && $id_networkmap == 0) {
|
|
||||||
$add_networkmap = 1;
|
|
||||||
}*/
|
|
||||||
|
|
||||||
// If the map id is not defined, we set the first id of the active type
|
// If the map id is not defined, we set the first id of the active type
|
||||||
if (!$nomaps && $id_networkmap == 0) {
|
if (!$nomaps && $id_networkmap == 0) {
|
||||||
|
@ -263,7 +260,8 @@ if (!empty($name)) {
|
||||||
$title .= " » ". mb_substr($name, 0, 25);
|
$title .= " » ". mb_substr($name, 0, 25);
|
||||||
}
|
}
|
||||||
|
|
||||||
ui_print_page_header (__('Network map')." - ".$title, "images/op_network.png", false, "network_map", false, $buttons);
|
ui_print_page_header (__('Network map') . " - " . $title,
|
||||||
|
"images/op_network.png", false, "network_map", false, $buttons);
|
||||||
|
|
||||||
if (tags_has_user_acl_tags()) {
|
if (tags_has_user_acl_tags()) {
|
||||||
ui_print_tags_warning();
|
ui_print_tags_warning();
|
||||||
|
@ -274,7 +272,8 @@ if ($delete_networkmap || $add_networkmap || $save_networkmap) {
|
||||||
}
|
}
|
||||||
|
|
||||||
if ($id_networkmap == 0) {
|
if ($id_networkmap == 0) {
|
||||||
echo "<div class='nf'>".__('There are no defined maps in this view')."</div>";
|
echo "<div class='nf'>" .
|
||||||
|
__('There are no defined maps in this view') . "</div>";
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -306,6 +305,7 @@ if ($activeTab == 'groups' || $activeTab == 'policies') {
|
||||||
$table->data[0][] = __('Module group') . ' ' .
|
$table->data[0][] = __('Module group') . ' ' .
|
||||||
html_print_select_from_sql ('SELECT id_mg, name FROM tmodule_group', 'module_group', $module_group, '', 'All', 0, true);
|
html_print_select_from_sql ('SELECT id_mg, name FROM tmodule_group', 'module_group', $module_group, '', 'All', 0, true);
|
||||||
}
|
}
|
||||||
|
|
||||||
if ($activeTab == 'topology') {
|
if ($activeTab == 'topology') {
|
||||||
$table->data[0][] = __('Show interfaces') . ' ' .
|
$table->data[0][] = __('Show interfaces') . ' ' .
|
||||||
html_print_checkbox ('show_snmp_modules', '1', $show_snmp_modules, true);
|
html_print_checkbox ('show_snmp_modules', '1', $show_snmp_modules, true);
|
||||||
|
@ -313,18 +313,25 @@ if ($activeTab == 'topology') {
|
||||||
$table->data[0][] = __('Layout') . ' ' .
|
$table->data[0][] = __('Layout') . ' ' .
|
||||||
html_print_select ($layout_array, 'layout', $layout, '', '', '', true);
|
html_print_select ($layout_array, 'layout', $layout, '', '', '', true);
|
||||||
if ($activeTab == 'groups') {
|
if ($activeTab == 'groups') {
|
||||||
$depth_levels = array('all' => __('All'), 'agent' => __('Agents'), 'group' => __('Groups'));
|
$depth_levels = array(
|
||||||
|
'all' => __('All'),
|
||||||
|
'agent' => __('Agents'),
|
||||||
|
'group' => __('Groups'));
|
||||||
$table->data[0][] = __('Depth') . ' ' .
|
$table->data[0][] = __('Depth') . ' ' .
|
||||||
html_print_select ($depth_levels, 'depth', $depth, '', '', '', true, false, false);
|
html_print_select ($depth_levels, 'depth', $depth, '', '', '', true, false, false);
|
||||||
}
|
}
|
||||||
|
|
||||||
if ($activeTab == 'policies') {
|
if ($activeTab == 'policies') {
|
||||||
$depth_levels = array('all' => __('All'), 'agent' => __('Agents'), 'policy' => __('Policies'));
|
$depth_levels = array(
|
||||||
|
'all' => __('All'),
|
||||||
|
'agent' => __('Agents'),
|
||||||
|
'policy' => __('Policies'));
|
||||||
$table->data[0][] = __('Depth') . ' ' .
|
$table->data[0][] = __('Depth') . ' ' .
|
||||||
html_print_select ($depth_levels, 'depth', $depth, '', '', '', true, false, false);
|
html_print_select ($depth_levels, 'depth', $depth, '', '', '', true, false, false);
|
||||||
}
|
}
|
||||||
$table->data[1][] = __('No Overlap') . ' ' .
|
$table->data[1][] = __('No Overlap') . ' ' .
|
||||||
html_print_checkbox ('nooverlap', '1', $nooverlap, true);
|
html_print_checkbox ('nooverlap', '1', $nooverlap, true);
|
||||||
|
|
||||||
if (($activeTab == 'groups' || $activeTab == 'policies') &&
|
if (($activeTab == 'groups' || $activeTab == 'policies') &&
|
||||||
$depth == 'all') {
|
$depth == 'all') {
|
||||||
$table->data[1][] = __('Only modules with alerts') . ' ' .
|
$table->data[1][] = __('Only modules with alerts') . ' ' .
|
||||||
|
@ -356,6 +363,7 @@ if ($pure == "1") {
|
||||||
$table->data[1][] = __('Zoom') . ' ' .
|
$table->data[1][] = __('Zoom') . ' ' .
|
||||||
html_print_select ($zoom_array, 'zoom', $zoom, '', '', '', true, false, false, false);
|
html_print_select ($zoom_array, 'zoom', $zoom, '', '', '', true, false, false, false);
|
||||||
}
|
}
|
||||||
|
|
||||||
if ($nooverlap == 1) {
|
if ($nooverlap == 1) {
|
||||||
$table->data[1][] = __('Distance between nodes') . ' ' .
|
$table->data[1][] = __('Distance between nodes') . ' ' .
|
||||||
html_print_input_text ('ranksep', $ranksep, __('Separation between elements in the map (in Non-overlap mode)'), 3, 4, true);
|
html_print_input_text ('ranksep', $ranksep, __('Separation between elements in the map (in Non-overlap mode)'), 3, 4, true);
|
||||||
|
@ -375,7 +383,7 @@ $options_form .= html_print_input_hidden('update_networkmap',1, true) .
|
||||||
html_print_input_hidden('hidden_options',0, true);
|
html_print_input_hidden('hidden_options',0, true);
|
||||||
$options_form .= html_print_table ($table, true);
|
$options_form .= html_print_table ($table, true);
|
||||||
$options_form .= "<div style='width: " . $table->width . "; text-align: right;'>" .
|
$options_form .= "<div style='width: " . $table->width . "; text-align: right;'>" .
|
||||||
html_print_submit_button (__('Apply'), "updbutton", false, 'class="sub next"', true) .
|
html_print_submit_button (__('Refresh'), "updbutton", false, 'class="sub next"', true) .
|
||||||
"</div>";
|
"</div>";
|
||||||
$options_form .= '</form>';
|
$options_form .= '</form>';
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue