今天遇到一个问题,有几个页面的图表,数据传递过来的是百分比的,比如 9.60% 25.05%.
解决办法是js中xml形式组装数据时,将百分号substring(0,colData.length-1);
然后<chart numberSuffix="%" decimals="2" >......,<set数据...此处略> </chart>
第一个参数是让数字之后有百分号.
第二个参数是官网上查的.
if you had data as 0.12352, 0.134 and 0.13, and you set decimals as 3, FusionCharts XT will output 0.124, 0.134 and 0.13
if you want your numbers on the chart to have trailing zeroes too, you can set <chart ... forceDecimals='1' > and now the numbers will show as 0.124, 0.134 and 0.130 respectively.