-1
我正打算来显示使用HighCharts.js
条形图。但系列属性中的数据未显示。见下图:简单条形图不显示图形
见下面我的代码:
exec_dashboard_load_graph(
'exec_dashboard_collection_disbursement_graph',
response,
['Jan', 'Feb', 'Mar', 'Apr', 'May', 'Jun', 'Jul', 'Aug', 'Sep', 'Oct', 'Nov', 'Dec']
);
function exec_dashboard_load_graph(id,data, x){
var myChart = Highcharts.chart(id, {
chart: {type: 'column'},
title: {text: 'Annual Collection and Disbursement Summary'},
subtitle:{text: 'City Goverment of Butuan'},
xAxis: {categories: x,crosshair: true},
yAxis: {min: 0,title: {text: 'Amount (Peso Value)'}},
tooltip: {
headerFormat: '<span style="font-size:10px">{point.key}</span><table>',
pointFormat: '<tr><td style="color:{series.color};padding:0">{series.name}: </td>' +
'<td style="padding:0"><b> {point.y:.1f} Php </b></td></tr>',
footerFormat: '</table>',
shared: true,
useHTML: true
},
plotOptions: {column: {pointPadding: 0.2,borderWidth: 0}},
series: data
});
}
数据变量包含以下值:
我不知道这有什么错我的数据。请帮忙。这是我的jsfiddle。
您可以创建一个plunker – Sajeetharan
@Sajeetharan - >我创建了一个的jsfiddle。往上看。 – Qerjiuthn