2011-03-30 14:34:25 +02:00
|
|
|
<?php
|
2011-04-01 14:28:50 +02:00
|
|
|
// Copyright (c) 2011-2011 Ártica Soluciones Tecnológicas
|
2011-03-30 14:34:25 +02:00
|
|
|
// http://www.artica.es <info@artica.es>
|
|
|
|
|
|
|
|
// This program is free software; you can redistribute it and/or
|
|
|
|
// modify it under the terms of the GNU General Public License
|
|
|
|
// as published by the Free Software Foundation; version 2
|
|
|
|
// This program is distributed in the hope that it will be useful,
|
|
|
|
// but WITHOUT ANY WARRANTY; without even the implied warranty of
|
|
|
|
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
|
|
|
// GNU General Public License for more details.
|
2018-10-19 12:01:22 +02:00
|
|
|
|
|
|
|
// Turn on output buffering.
|
|
|
|
// The entire buffer will be discarded later so that any accidental output
|
|
|
|
// does not corrupt images generated by fgraph.
|
|
|
|
ob_start();
|
|
|
|
|
|
|
|
global $config;
|
|
|
|
|
|
|
|
if (empty($config['homedir'])) {
|
|
|
|
require_once ('../../include/config.php');
|
|
|
|
global $config;
|
|
|
|
}
|
|
|
|
|
|
|
|
include_once($config['homedir'] . '/include/functions.php');
|
|
|
|
|
|
|
|
$ttl = get_parameter('ttl', 1);
|
|
|
|
$graph_type = get_parameter('graph_type', '');
|
|
|
|
|
|
|
|
if (!empty($graph_type)) {
|
|
|
|
include_once($config['homedir'] . '/include/functions_html.php');
|
|
|
|
include_once($config['homedir'] . '/include/graphs/functions_gd.php');
|
|
|
|
include_once($config['homedir'] . '/include/graphs/functions_utils.php');
|
|
|
|
include_once($config['homedir'] . '/include/graphs/functions_d3.php');
|
|
|
|
include_once($config['homedir'] . '/include/graphs/functions_flot.php');
|
|
|
|
}
|
|
|
|
|
|
|
|
// Clean the output buffer and turn off output buffering
|
|
|
|
ob_end_clean ();
|
|
|
|
|
|
|
|
switch($graph_type) {
|
|
|
|
case 'histogram':
|
|
|
|
$width = get_parameter('width');
|
|
|
|
$height = get_parameter('height');
|
|
|
|
$data = json_decode(io_safe_output(get_parameter('data')), true);
|
|
|
|
|
|
|
|
$max = get_parameter('max');
|
|
|
|
$title = get_parameter('title');
|
|
|
|
$mode = get_parameter ('mode', 1);
|
|
|
|
gd_histogram ($width, $height, $mode, $data, $max, $config['fontpath'], $title);
|
|
|
|
break;
|
|
|
|
case 'progressbar':
|
|
|
|
$width = get_parameter('width');
|
|
|
|
$height = get_parameter('height');
|
|
|
|
$progress = get_parameter('progress');
|
|
|
|
|
|
|
|
$out_of_lim_str = io_safe_output(get_parameter('out_of_lim_str', false));
|
|
|
|
$out_of_lim_image = get_parameter('out_of_lim_image', false);
|
|
|
|
|
|
|
|
$title = get_parameter('title');
|
|
|
|
|
|
|
|
$mode = get_parameter('mode', 1);
|
|
|
|
|
|
|
|
$fontsize = get_parameter('fontsize', 10);
|
|
|
|
|
|
|
|
$value_text = get_parameter('value_text', '');
|
|
|
|
$colorRGB = get_parameter('colorRGB', '');
|
|
|
|
|
|
|
|
gd_progress_bar ($width, $height, $progress, $title, $config['fontpath'],
|
|
|
|
$out_of_lim_str, $out_of_lim_image, $mode, $fontsize,
|
|
|
|
$value_text, $colorRGB);
|
|
|
|
break;
|
|
|
|
case 'progressbubble':
|
|
|
|
$width = get_parameter('width');
|
|
|
|
$height = get_parameter('height');
|
|
|
|
$progress = get_parameter('progress');
|
|
|
|
|
|
|
|
$out_of_lim_str = io_safe_output(get_parameter('out_of_lim_str', false));
|
|
|
|
$out_of_lim_image = get_parameter('out_of_lim_image', false);
|
|
|
|
|
|
|
|
$title = get_parameter('title');
|
|
|
|
|
|
|
|
$mode = get_parameter('mode', 1);
|
|
|
|
|
|
|
|
$fontsize = get_parameter('fontsize', 7);
|
|
|
|
|
|
|
|
$value_text = get_parameter('value_text', '');
|
|
|
|
$colorRGB = get_parameter('colorRGB', '');
|
|
|
|
|
|
|
|
gd_progress_bubble ($width, $height, $progress, $title, $config['fontpath'],
|
|
|
|
$out_of_lim_str, $out_of_lim_image, $mode, $fontsize,
|
|
|
|
$value_text, $colorRGB);
|
|
|
|
break;
|
|
|
|
}
|
|
|
|
|
2014-09-23 13:02:49 +02:00
|
|
|
function progressbar($progress, $width, $height, $title, $font,
|
|
|
|
$mode = 1, $out_of_lim_str = false, $out_of_lim_image = false,
|
|
|
|
$ttl = 1) {
|
2018-02-27 16:28:00 +01:00
|
|
|
|
2011-04-14 10:25:41 +02:00
|
|
|
$graph = array();
|
2018-02-27 16:28:00 +01:00
|
|
|
|
2011-04-14 10:25:41 +02:00
|
|
|
$graph['progress'] = $progress;
|
|
|
|
$graph['width'] = $width;
|
|
|
|
$graph['height'] = $height;
|
|
|
|
$graph['out_of_lim_str'] = $out_of_lim_str;
|
|
|
|
$graph['out_of_lim_image'] = $out_of_lim_image;
|
|
|
|
$graph['title'] = $title;
|
|
|
|
$graph['font'] = $font;
|
|
|
|
$graph['mode'] = $mode;
|
2018-02-27 16:28:00 +01:00
|
|
|
|
2011-06-14 10:46:57 +02:00
|
|
|
$id_graph = serialize_in_temp($graph, null, $ttl);
|
2017-04-05 10:26:12 +02:00
|
|
|
if (is_metaconsole()) {
|
|
|
|
return "<img src='../../include/graphs/functions_gd.php?static_graph=1&graph_type=progressbar&ttl=".$ttl."&id_graph=".$id_graph."'>";
|
|
|
|
}
|
|
|
|
else {
|
|
|
|
return "<img src='include/graphs/functions_gd.php?static_graph=1&graph_type=progressbar&ttl=".$ttl."&id_graph=".$id_graph."'>";
|
|
|
|
}
|
2011-04-14 10:25:41 +02:00
|
|
|
}
|
|
|
|
|
2018-03-01 12:02:08 +01:00
|
|
|
function vbar_graph(
|
|
|
|
$chart_data,
|
|
|
|
$width,
|
|
|
|
$height,
|
|
|
|
$color,
|
|
|
|
$legend,
|
|
|
|
$long_index,
|
|
|
|
$no_data_image,
|
|
|
|
$xaxisname = "",
|
|
|
|
$yaxisname = "",
|
|
|
|
$water_mark = "",
|
|
|
|
$font = '',
|
|
|
|
$font_size = '',
|
|
|
|
$unit = '',
|
|
|
|
$ttl = 1,
|
|
|
|
$homeurl = '',
|
|
|
|
$backgroundColor = 'white',
|
|
|
|
$from_ux = false,
|
|
|
|
$from_wux = false,
|
2018-06-08 08:58:18 +02:00
|
|
|
$tick_color = 'white') {
|
2018-03-01 12:02:08 +01:00
|
|
|
|
2012-03-01 17:41:02 +01:00
|
|
|
setup_watermark($water_mark, $water_mark_file, $water_mark_url);
|
2018-02-27 16:28:00 +01:00
|
|
|
|
2015-11-25 14:25:19 +01:00
|
|
|
if (empty($chart_data)) {
|
2018-11-29 13:24:12 +01:00
|
|
|
return html_print_image (
|
|
|
|
$no_data_image,
|
|
|
|
true,
|
|
|
|
array(
|
|
|
|
'width' => $width,
|
|
|
|
'height' => $height,
|
|
|
|
'title' => __('No data to show')
|
|
|
|
),
|
|
|
|
false,
|
|
|
|
true
|
|
|
|
);
|
2015-11-25 14:25:19 +01:00
|
|
|
}
|
2018-02-27 16:28:00 +01:00
|
|
|
|
2018-10-16 15:32:31 +02:00
|
|
|
if($ttl == 2){
|
|
|
|
$params = array(
|
|
|
|
'chart_data' => $chart_data,
|
|
|
|
'width' => $width,
|
|
|
|
'height' => $height,
|
|
|
|
'color' => $color,
|
|
|
|
'legend' => $legend,
|
|
|
|
'long_index' => $long_index,
|
|
|
|
'homeurl' => $homeurl,
|
|
|
|
'unit' => $unit,
|
|
|
|
'water_mark_url' => $water_mark_url,
|
|
|
|
'homedir' => $homedir,
|
|
|
|
'font' => $font,
|
|
|
|
'font_size' => $font_size,
|
|
|
|
'from_ux' => $from_ux,
|
|
|
|
'from_wux' => $from_wux,
|
|
|
|
'backgroundColor' => $backgroundColor,
|
|
|
|
'tick_color' => $tick_color
|
|
|
|
);
|
|
|
|
return generator_chart_to_pdf('vbar', $params);
|
|
|
|
}
|
2018-02-27 16:28:00 +01:00
|
|
|
|
2018-10-16 15:32:31 +02:00
|
|
|
return flot_vcolumn_chart (
|
|
|
|
$chart_data,
|
|
|
|
$width,
|
|
|
|
$height,
|
|
|
|
$color,
|
|
|
|
$legend,
|
|
|
|
$long_index,
|
|
|
|
$homeurl,
|
|
|
|
$unit,
|
|
|
|
$water_mark_url,
|
|
|
|
$homedir,
|
|
|
|
$font,
|
|
|
|
$font_size,
|
|
|
|
$from_ux,
|
|
|
|
$from_wux,
|
|
|
|
$backgroundColor,
|
|
|
|
$tick_color
|
|
|
|
);
|
2011-03-30 14:34:25 +02:00
|
|
|
}
|
|
|
|
|
2018-02-27 16:28:00 +01:00
|
|
|
function area_graph(
|
2018-05-21 17:25:09 +02:00
|
|
|
$agent_module_id, $array_data,
|
2018-06-08 14:30:15 +02:00
|
|
|
$legend, $series_type, $color, $date_array,
|
2018-06-06 11:18:39 +02:00
|
|
|
$data_module_graph, $params, $water_mark,
|
2018-06-08 08:58:18 +02:00
|
|
|
$array_events_alerts) {
|
2018-02-27 16:28:00 +01:00
|
|
|
global $config;
|
2011-03-30 14:34:25 +02:00
|
|
|
|
2016-04-18 14:18:44 +02:00
|
|
|
include_once('functions_flot.php');
|
2018-04-27 13:51:13 +02:00
|
|
|
|
2018-06-08 08:58:18 +02:00
|
|
|
setup_watermark($water_mark, $water_mark_file, $water_mark_url);
|
2018-06-07 09:15:45 +02:00
|
|
|
|
2018-05-28 17:47:40 +02:00
|
|
|
return flot_area_graph(
|
|
|
|
$agent_module_id,
|
|
|
|
$array_data,
|
|
|
|
$legend,
|
|
|
|
$series_type,
|
2018-06-08 14:30:15 +02:00
|
|
|
$color,
|
2018-05-28 17:47:40 +02:00
|
|
|
$date_array,
|
|
|
|
$data_module_graph,
|
|
|
|
$params,
|
|
|
|
$water_mark,
|
|
|
|
$array_events_alerts
|
|
|
|
);
|
2011-04-07 19:36:08 +02:00
|
|
|
}
|
|
|
|
|
2018-06-06 11:18:39 +02:00
|
|
|
function stacked_bullet_chart($chart_data, $width, $height,
|
2015-11-04 17:42:45 +01:00
|
|
|
$color, $legend, $long_index, $no_data_image, $xaxisname = "",
|
|
|
|
$yaxisname = "", $water_mark = "", $font = '', $font_size = '',
|
|
|
|
$unit = '', $ttl = 1, $homeurl = '', $backgroundColor = 'white') {
|
2018-02-27 16:28:00 +01:00
|
|
|
|
2015-11-04 17:42:45 +01:00
|
|
|
include_once('functions_d3.php');
|
2018-02-27 16:28:00 +01:00
|
|
|
|
2015-11-04 17:42:45 +01:00
|
|
|
setup_watermark($water_mark, $water_mark_file, $water_mark_url);
|
2018-02-27 16:28:00 +01:00
|
|
|
|
2015-11-04 17:42:45 +01:00
|
|
|
if (empty($chart_data)) {
|
|
|
|
return '<img src="' . $no_data_image . '" />';
|
|
|
|
}
|
2018-02-27 16:28:00 +01:00
|
|
|
|
2018-06-06 11:18:39 +02:00
|
|
|
return d3_bullet_chart(
|
|
|
|
$chart_data,
|
|
|
|
$width,
|
|
|
|
$height,
|
|
|
|
$color,
|
|
|
|
$legend,
|
|
|
|
$homeurl,
|
|
|
|
$unit,
|
|
|
|
$font,
|
|
|
|
$font_size
|
|
|
|
);
|
2018-02-27 16:28:00 +01:00
|
|
|
|
2015-11-04 17:42:45 +01:00
|
|
|
}
|
|
|
|
|
2018-06-06 11:18:39 +02:00
|
|
|
function stacked_gauge($chart_data, $width, $height,
|
|
|
|
$color, $legend, $no_data_image, $font = '', $font_size = '',
|
|
|
|
$unit = '', $homeurl = '') {
|
2018-02-27 16:28:00 +01:00
|
|
|
|
2015-11-04 17:42:45 +01:00
|
|
|
include_once('functions_d3.php');
|
2018-02-27 16:28:00 +01:00
|
|
|
|
2015-11-04 17:42:45 +01:00
|
|
|
if (empty($chart_data)) {
|
|
|
|
return '<img src="' . $no_data_image . '" />';
|
|
|
|
}
|
2018-02-27 16:28:00 +01:00
|
|
|
|
2015-11-04 17:42:45 +01:00
|
|
|
return d3_gauges(
|
2018-06-06 11:18:39 +02:00
|
|
|
$chart_data,
|
|
|
|
$width,
|
|
|
|
$height,
|
|
|
|
$color,
|
|
|
|
$legend,
|
|
|
|
$homeurl,
|
|
|
|
$unit,
|
|
|
|
$font,
|
|
|
|
$font_size + 2,
|
|
|
|
$no_data_image
|
|
|
|
);
|
2015-11-04 17:42:45 +01:00
|
|
|
}
|
|
|
|
|
2018-10-16 15:32:31 +02:00
|
|
|
function hbar_graph($chart_data, $width, $height,
|
2015-11-25 14:25:19 +01:00
|
|
|
$color, $legend, $long_index, $no_data_image, $xaxisname = "",
|
|
|
|
$yaxisname = "", $water_mark = "", $font = '', $font_size = '',
|
2017-11-08 09:55:36 +01:00
|
|
|
$unit = '', $ttl = 1, $homeurl = '', $backgroundColor = 'white',
|
2017-11-14 10:49:15 +01:00
|
|
|
$tick_color = "white", $val_min=null, $val_max=null) {
|
2018-02-27 16:28:00 +01:00
|
|
|
|
2012-03-01 17:41:02 +01:00
|
|
|
setup_watermark($water_mark, $water_mark_file, $water_mark_url);
|
2018-02-27 16:28:00 +01:00
|
|
|
|
2015-11-25 14:25:19 +01:00
|
|
|
if (empty($chart_data)) {
|
2018-11-29 13:24:12 +01:00
|
|
|
return html_print_image (
|
|
|
|
$no_data_image,
|
|
|
|
true,
|
|
|
|
array(
|
|
|
|
'width' => $width,
|
|
|
|
'height' => $height,
|
|
|
|
'title' => __('No data to show')
|
|
|
|
),
|
|
|
|
false,
|
|
|
|
true
|
|
|
|
);
|
2015-11-25 14:25:19 +01:00
|
|
|
}
|
2018-02-27 16:28:00 +01:00
|
|
|
|
2018-10-16 15:32:31 +02:00
|
|
|
if($ttl == 2){
|
|
|
|
$params = array(
|
|
|
|
'chart_data' => $chart_data,
|
|
|
|
'width' => $width,
|
|
|
|
'height' => $height,
|
|
|
|
'water_mark_url' => $water_mark_url,
|
|
|
|
'font' => $font,
|
|
|
|
'font_size' => $font_size,
|
|
|
|
'backgroundColor' => $backgroundColor,
|
|
|
|
'tick_color' => $tick_color,
|
|
|
|
'val_min' => $val_min,
|
|
|
|
'val_max' => $val_max
|
|
|
|
);
|
|
|
|
return generator_chart_to_pdf('hbar', $params);
|
2011-03-30 14:34:25 +02:00
|
|
|
}
|
2018-02-27 16:28:00 +01:00
|
|
|
|
2018-10-16 15:32:31 +02:00
|
|
|
return flot_hcolumn_chart(
|
|
|
|
$chart_data,
|
|
|
|
$width,
|
|
|
|
$height,
|
|
|
|
$water_mark_url,
|
|
|
|
$font,
|
|
|
|
$font_size,
|
|
|
|
$backgroundColor,
|
|
|
|
$tick_color,
|
|
|
|
$val_min,
|
|
|
|
$val_max
|
|
|
|
);
|
2011-03-30 14:34:25 +02:00
|
|
|
}
|
|
|
|
|
2018-10-11 12:57:48 +02:00
|
|
|
function pie_graph($chart_data, $width,
|
2014-09-23 13:02:49 +02:00
|
|
|
$height, $others_str = "other", $homedir="", $water_mark = "",
|
2018-10-11 12:57:48 +02:00
|
|
|
$font = '', $font_size = 8, $ttl = 1, $legend_position = false,
|
2016-05-26 13:47:45 +02:00
|
|
|
$colors = '', $hide_labels = false) {
|
2018-02-27 16:28:00 +01:00
|
|
|
|
2013-06-10 13:13:38 +02:00
|
|
|
if (empty($chart_data)) {
|
2013-05-23 17:42:32 +02:00
|
|
|
return graph_nodata_image($width, $height, 'pie');
|
|
|
|
}
|
2018-02-27 16:28:00 +01:00
|
|
|
|
2012-03-01 17:41:02 +01:00
|
|
|
setup_watermark($water_mark, $water_mark_file, $water_mark_url);
|
2018-02-27 16:28:00 +01:00
|
|
|
|
2011-04-14 14:02:45 +02:00
|
|
|
// This library allows only 8 colors
|
2018-03-01 13:19:58 +01:00
|
|
|
$max_values = 9;
|
2018-02-27 16:28:00 +01:00
|
|
|
|
2013-06-20 10:20:11 +02:00
|
|
|
//Remove the html_entities
|
|
|
|
$temp = array();
|
|
|
|
foreach ($chart_data as $key => $value) {
|
|
|
|
$temp[io_safe_output($key)] = $value;
|
|
|
|
}
|
|
|
|
$chart_data = $temp;
|
2018-02-27 16:28:00 +01:00
|
|
|
|
2013-01-30 17:29:49 +01:00
|
|
|
if (count($chart_data) > $max_values) {
|
2011-03-30 14:34:25 +02:00
|
|
|
$chart_data_trunc = array();
|
|
|
|
$n = 1;
|
2013-02-19 Miguel de Dios <miguel.dedios@artica.es>
* include/functions_api.php, include/functions_agents.php,
include/functions_config.php, include/ajax/reporting.ajax.php,
include/functions_snmp_browser.php,
operation/agentes/status_monitor.php: improved code style.
* include/functions_graph.php, include/graphs/fgraph.php,
include/graphs/flot/jquery.flot.pie.js,
include/graphs/flot/jquery.flot.pie.min.js,
include/graphs/flot/pandora.flot.js,
include/graphs/functions_flot.php: fixed the pie graphs, added the
expanded version of flot pie js file with some changes for the
last version of jQuery.
Fixes: #3604555
git-svn-id: https://svn.code.sf.net/p/pandora/code/trunk@7675 c3f86ba8-e40f-0410-aaad-9ba5e7f4b01f
2013-02-19 11:35:04 +01:00
|
|
|
foreach ($chart_data as $key => $value) {
|
|
|
|
if ($n < $max_values) {
|
2011-03-30 14:34:25 +02:00
|
|
|
$chart_data_trunc[$key] = $value;
|
|
|
|
}
|
|
|
|
else {
|
2011-04-14 14:02:45 +02:00
|
|
|
if (!isset($chart_data_trunc[$others_str])) {
|
|
|
|
$chart_data_trunc[$others_str] = 0;
|
|
|
|
}
|
2011-03-30 14:34:25 +02:00
|
|
|
$chart_data_trunc[$others_str] += $value;
|
|
|
|
}
|
|
|
|
$n++;
|
|
|
|
}
|
|
|
|
$chart_data = $chart_data_trunc;
|
|
|
|
}
|
2018-02-27 16:28:00 +01:00
|
|
|
|
2018-10-11 12:57:48 +02:00
|
|
|
if($ttl == 2){
|
2018-10-16 15:32:31 +02:00
|
|
|
$params = array(
|
|
|
|
'values' => array_values($chart_data),
|
|
|
|
'keys' => array_keys($chart_data),
|
|
|
|
'width' => $width,
|
|
|
|
'height' => $height,
|
|
|
|
'water_mark_url' => $water_mark_url,
|
|
|
|
'font' => $font,
|
|
|
|
'font_size' => $font_size,
|
|
|
|
'legend_position' => $legend_position,
|
|
|
|
'colors' => $colors,
|
|
|
|
'hide_labels' => $hide_labels
|
|
|
|
);
|
|
|
|
|
2018-10-11 12:57:48 +02:00
|
|
|
return generator_chart_to_pdf('pie_chart', $params);
|
2011-03-30 14:34:25 +02:00
|
|
|
}
|
2018-10-11 12:57:48 +02:00
|
|
|
|
|
|
|
return flot_pie_chart(
|
|
|
|
array_values($chart_data),
|
|
|
|
array_keys($chart_data),
|
|
|
|
$width,
|
|
|
|
$height,
|
|
|
|
$water_mark_url,
|
|
|
|
$font,
|
|
|
|
$font_size,
|
|
|
|
$legend_position,
|
|
|
|
$colors,
|
|
|
|
$hide_labels
|
|
|
|
);
|
2011-03-30 14:34:25 +02:00
|
|
|
}
|
|
|
|
|
2018-10-16 15:32:31 +02:00
|
|
|
function ring_graph($chart_data, $width,
|
2016-06-10 11:11:11 +02:00
|
|
|
$height, $others_str = "other", $homedir="", $water_mark = "",
|
|
|
|
$font = '', $font_size = '', $ttl = 1, $legend_position = false,
|
2017-10-09 12:03:19 +02:00
|
|
|
$colors = '', $hide_labels = false,$background_color = 'white') {
|
2018-02-27 16:28:00 +01:00
|
|
|
|
2016-06-10 11:11:11 +02:00
|
|
|
if (empty($chart_data)) {
|
|
|
|
return graph_nodata_image($width, $height, 'pie');
|
|
|
|
}
|
2018-02-27 16:28:00 +01:00
|
|
|
|
2016-06-10 11:11:11 +02:00
|
|
|
setup_watermark($water_mark, $water_mark_file, $water_mark_url);
|
2018-02-27 16:28:00 +01:00
|
|
|
|
2016-06-10 11:11:11 +02:00
|
|
|
// This library allows only 8 colors
|
|
|
|
$max_values = 18;
|
2018-02-27 16:28:00 +01:00
|
|
|
|
2018-10-16 15:32:31 +02:00
|
|
|
if($ttl == 2){
|
|
|
|
$params = array(
|
|
|
|
'chart_data' => $chart_data,
|
|
|
|
'width' => $width,
|
|
|
|
'height' => $height,
|
|
|
|
'colors' => $colors,
|
|
|
|
'module_name_list' => $module_name_list,
|
|
|
|
'long_index' => $long_index,
|
|
|
|
'no_data' => $no_data,
|
|
|
|
'water_mark' => $water_mark,
|
|
|
|
'font' => $font,
|
|
|
|
'font_size' => $font_size,
|
|
|
|
'unit' => $unit,
|
|
|
|
'ttl' => $ttl,
|
|
|
|
'homeurl' => $homeurl,
|
|
|
|
'background_color' => $background_color,
|
|
|
|
'legend_position' => $legend_position,
|
|
|
|
'background_color' => $background_color
|
|
|
|
);
|
|
|
|
|
|
|
|
return generator_chart_to_pdf('ring_graph', $params);
|
2016-06-10 11:11:11 +02:00
|
|
|
}
|
2018-02-27 16:28:00 +01:00
|
|
|
|
2018-10-16 15:32:31 +02:00
|
|
|
return flot_custom_pie_chart (
|
|
|
|
$chart_data,
|
|
|
|
$width,
|
|
|
|
$height,
|
|
|
|
$colors,
|
|
|
|
$module_name_list,
|
|
|
|
$long_index,
|
|
|
|
$no_data,
|
|
|
|
false,
|
|
|
|
'',
|
|
|
|
$water_mark,
|
|
|
|
$font,
|
|
|
|
$font_size,
|
|
|
|
$unit,
|
|
|
|
$ttl,
|
|
|
|
$homeurl,
|
|
|
|
$background_color,
|
|
|
|
$legend_position,
|
|
|
|
$background_color
|
|
|
|
);
|
2016-06-10 11:11:11 +02:00
|
|
|
}
|
|
|
|
|
2011-03-30 14:34:25 +02:00
|
|
|
?>
|