diff --git a/pandora_console/include/graphs/functions_flot.php b/pandora_console/include/graphs/functions_flot.php
index d1856b7b4c..754e428168 100644
--- a/pandora_console/include/graphs/functions_flot.php
+++ b/pandora_console/include/graphs/functions_flot.php
@@ -252,7 +252,7 @@ function flot_area_graph(
$return .= html_print_input_hidden(
'line_width_graph',
- $config['custom_graph_width'],
+ (empty($params['line_width']) === true) ? $config['custom_graph_width'] : $params['line_width'],
true
);
$return .= "
__('Area'),
+ 'line' => __('Wire'),
+ ];
+
+ $inputs['inputs']['row1'][] = [
+ 'label' => __('Type graph'),
+ 'arguments' => [
+ 'type' => 'select',
+ 'fields' => $types_graph,
+ 'name' => 'type_graph',
+ 'selected' => $values['type_graph'],
+ 'return' => true,
+ ],
+ ];
+
$inputs['inputs']['row2'][] = [
'label' => __('Show Value'),
'arguments' => [
@@ -520,6 +544,18 @@ class BasicChart extends Widget
],
];
+ $inputs['inputs']['row2'][] = [
+ 'label' => __('Graph line size'),
+ 'arguments' => [
+ 'name' => 'line_width',
+ 'type' => 'number',
+ 'value' => (empty($values['line_width']) === true) ? 3 : $values['line_width'],
+ 'return' => true,
+ 'min' => 2,
+ 'max' => 10,
+ ],
+ ];
+
return $inputs;
}
@@ -546,6 +582,8 @@ class BasicChart extends Widget
$values['colorChart'] = \get_parameter('colorChart');
$values['formatData'] = \get_parameter_switch('formatData');
$values['label'] = \get_parameter('label');
+ $values['type_graph'] = \get_parameter('type_graph');
+ $values['line_width'] = \get_parameter('line_width');
return $values;
}
@@ -606,6 +644,8 @@ class BasicChart extends Widget
'title' => $module_name,
'unit' => $units_name,
'only_image' => false,
+ 'type_graph' => $this->values['type_graph'],
+ 'line_width' => (empty($this->values['line_width']) === true) ? 3 : $this->values['line_width'],
'menu' => false,
'vconsole' => true,
'return_img_base_64' => false,