Merge branch 'ent-5971-10211-error-click-en-el-evento-de-grafica-modulo' into 'develop'

fix event legend

See merge request artica/pandorafms!3458
This commit is contained in:
Daniel Rodriguez 2020-09-18 10:05:35 +02:00
commit f8152d5ee5
2 changed files with 16 additions and 18 deletions

View File

@ -1918,8 +1918,7 @@ function pandoraFlotArea(
case "points":
line_show = false;
points_show = true;
filled = false;
steps_chart = false;
filled = true;
radius = 3;
fill_points = fill_color;
break;
@ -1959,7 +1958,8 @@ function pandoraFlotArea(
points: {
show: points_show,
radius: radius,
fillColor: fill_points
fillColor: fill_points,
fill: filled
},
legend: legend.index
});
@ -2521,7 +2521,7 @@ function pandoraFlotArea(
plot.unhighlight();
$("#extra_" + graph_id).css("width", "170px");
$("#extra_" + graph_id).css("height", "60px");
$("#extra_" + graph_id).css("height", "auto");
var extra_info = "<i>No info to show</i>";
var extra_show = false;
@ -2537,7 +2537,7 @@ function pandoraFlotArea(
var width_graph = plot.width();
var height_legend = $("#legend_" + graph_id).height();
var coord_x = pos.pageX - offset_relative.left + offset_graph.left;
var coord_y = offset_graph.top + height_legend + extra_height;
var coord_y = offset_graph.top + height_legend + extra_height + 50;
if (coord_x + extra_width > width_graph) {
coord_x = coord_x - extra_width;

View File

@ -279,20 +279,18 @@ function flot_area_graph(
$series_type_unique['data_'.$graph_id.'_'.$k] = $v;
}
/*
// Store data series in javascript format.
$extra_width = (int) ($params['width'] / 3);
$return .= "<div id='extra_$graph_id'
style='font-size: ".$params['font_size'].'pt;
display:none; position:absolute; overflow: auto;
max-height: '.($params['height'] + 50).'px;
width: '.$extra_width."px;
background:#fff; padding: 2px 2px 2px 2px;
border: solid #000 1px;'></div>";
// Store data series in javascript format.
$extra_width = (int) ($params['width'] / 3);
$return .= "<div id='extra_$graph_id'
style='font-size: ".$params['font_size'].'pt;
display:none; position:absolute; overflow: auto;
max-height: '.($params['height'] + 50).'px;
width: '.$extra_width."px;
background:#fff; padding: 2px 2px 2px 2px;
border: solid #000 1px;'></div>";
// Trick to get translated string from javascript.
$return .= html_print_input_hidden('unknown_text', __('Unknown'), true);
*/
// Trick to get translated string from javascript.
$return .= html_print_input_hidden('unknown_text', __('Unknown'), true);
$values = json_encode($array_data);