2013-06-24 Miguel de Dios <miguel.dedios@artica.es>
* include/functions_visual_map.php, include/ajax/visual_console_builder.ajax.php: fixed the color of lines in the editor. MERGED FROM THE BRANCH PANDORA_4.0 git-svn-id: https://svn.code.sf.net/p/pandora/code/trunk@8376 c3f86ba8-e40f-0410-aaad-9ba5e7f4b01f
This commit is contained in:
parent
92e3786e2d
commit
8bde8df48b
|
@ -1,3 +1,11 @@
|
|||
2013-06-24 Miguel de Dios <miguel.dedios@artica.es>
|
||||
|
||||
* include/functions_visual_map.php,
|
||||
include/ajax/visual_console_builder.ajax.php: fixed the color of
|
||||
lines in the editor.
|
||||
|
||||
MERGED FROM THE BRANCH PANDORA_4.0
|
||||
|
||||
2013-06-24 Miguel de Dios <miguel.dedios@artica.es>
|
||||
|
||||
* godmode/reporting/visual_console_builder.editor.js,
|
||||
|
|
|
@ -272,9 +272,10 @@ switch ($action) {
|
|||
|
||||
case 'get_color_line':
|
||||
$layoutData = db_get_row_filter('tlayout_data', array('id' => $id_element));
|
||||
$parent = db_get_row_filter('tlayout_data', array('id' => $layoutData['parent_item']));
|
||||
|
||||
$return = array();
|
||||
$return['color_line'] = visual_map_get_color_line_status($layoutData);
|
||||
$return['color_line'] = visual_map_get_color_line_status($parent);
|
||||
echo json_encode($return);
|
||||
break;
|
||||
|
||||
|
|
|
@ -268,9 +268,11 @@ function visual_map_print_item($layoutData) {
|
|||
|
||||
//Add the line between elements.
|
||||
if ($layoutData['parent_item'] != 0) {
|
||||
$parent = db_get_row_filter('tlayout_data', array('id' => $layoutData['parent_item']));
|
||||
|
||||
echo '<script type="text/javascript">';
|
||||
echo '$(document).ready (function() {
|
||||
lines.push({"id": "' . $id . '" , "node_begin":"' . $layoutData['parent_item'] . '","node_end":"' . $id . '","color":"' . visual_map_get_color_line_status($layoutData) . '"});
|
||||
lines.push({"id": "' . $id . '" , "node_begin":"' . $layoutData['parent_item'] . '","node_end":"' . $id . '","color":"' . visual_map_get_color_line_status($parent) . '"});
|
||||
});';
|
||||
echo '</script>';
|
||||
}
|
||||
|
@ -1077,6 +1079,7 @@ function visual_map_print_visual_map ($id_layout, $show_links = true, $draw_line
|
|||
echo '<a href="#">';
|
||||
}
|
||||
}
|
||||
|
||||
$img_style = array ();
|
||||
$img_style["title"] = $layout_data["label"];
|
||||
|
||||
|
@ -1087,17 +1090,17 @@ function visual_map_print_visual_map ($id_layout, $show_links = true, $draw_line
|
|||
$img_style["height"] = $layout_data["height"];
|
||||
}
|
||||
|
||||
$img = "images/console/icons/" . $layout_data["image"];
|
||||
$img = "images/console/icons/" . $layout_data["image"];
|
||||
|
||||
switch ($status) {
|
||||
case VISUAL_MAP_STATUS_CRITICAL_BAD:
|
||||
$img .= "_bad.png";
|
||||
break;
|
||||
case VISUAL_MAP_STATUS_CRITICAL_ALERT:
|
||||
$img = "4".$img."_bad.png";
|
||||
$img = "4" . $img . "_bad.png";
|
||||
break;
|
||||
case VISUAL_MAP_STATUS_WARNING_ALERT:
|
||||
$img = "4".$img."_warning.png";
|
||||
$img = "4" . $img . "_warning.png";
|
||||
break;
|
||||
case VISUAL_MAP_STATUS_NORMAL:
|
||||
$img .= "_ok.png";
|
||||
|
@ -1756,6 +1759,7 @@ function visual_map_get_user_layouts ($id_user = 0, $only_names = false, $filter
|
|||
return $retval;
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* Get the status of a layout.
|
||||
*
|
||||
|
|
Loading…
Reference in New Issue