2013-12-11 Sergio Martin <sergio.martin@artica.es>

* include/graphs/flot/pandora.flot.js: Add one decimal
	to pie graphs to don't lose so much precision when 
	percentages are rounded
	Incident #407



git-svn-id: https://svn.code.sf.net/p/pandora/code/trunk@9209 c3f86ba8-e40f-0410-aaad-9ba5e7f4b01f
This commit is contained in:
zarzuelo 2013-12-11 12:57:09 +00:00
parent fc92ed1c62
commit a77beeb7f7
2 changed files with 8 additions and 1 deletions

View File

@ -1,3 +1,10 @@
2013-12-11 Sergio Martin <sergio.martin@artica.es>
* include/graphs/flot/pandora.flot.js: Add one decimal
to pie graphs to don't lose so much precision when
percentages are rounded
Incident #407
2013-12-10 Dario Rodriguez <dario@artica.es> 2013-12-10 Dario Rodriguez <dario@artica.es>
* mobile/operation/modules.php, * mobile/operation/modules.php,

View File

@ -33,7 +33,7 @@ function pandoraFlotPie(graph_id, values, labels, nseries, width, font_size, wat
formatter: function(label, series) { formatter: function(label, series) {
return '<div style="font-size:' + font_size + 'pt;' + return '<div style="font-size:' + font_size + 'pt;' +
'text-align:center;padding:2px;color:white;">' + 'text-align:center;padding:2px;color:white;">' +
label + '<br/>' + Math.round(series.percent) + '%</div>'; label + '<br/>' + series.percent.toFixed(1) + '%</div>';
}, },
background: { background: {
opacity: 0.5, opacity: 0.5,