diff --git a/htdocs/lib/functions.lib.php b/htdocs/lib/functions.lib.php index 64eb2c033f0..b8907b45c50 100644 --- a/htdocs/lib/functions.lib.php +++ b/htdocs/lib/functions.lib.php @@ -1238,8 +1238,9 @@ function dolibarr_trunc($string,$size=40,$trunc='right',$stringencoding='') * @param showlegend Show legend * @param type Type of graph ('pie', 'barline') * @param showpercent Show percent (with type='pie' only) + * @param url Param to add an url to click values */ -function dol_print_graph($htmlid,$width,$height,$data,$showlegend=0,$type='pie',$showpercent=0) +function dol_print_graph($htmlid,$width,$height,$data,$showlegend=0,$type='pie',$showpercent=0,$url='') { global $conf,$langs; global $theme_datacolor; // To have var kept when function is called several times @@ -1301,9 +1302,14 @@ function dol_print_graph($htmlid,$width,$height,$data,$showlegend=0,$type='pie', formatter: function(label, series) { var percent=Math.round(series.percent); var number=series.data[0][1]; - return \'