目前我正在使用meteorjs 0.9.2和highcharts 4.0.4
但是highcharts pie drilldown不起作用,它显示了一个饼图,但点击该饼上的事件不起作用,所以我无法在饼上钻取
我认为在使用meteorjs的highcharts中存在一些问题,格式化程序无法正常工作
所有其他事件除了我测试的工作正常
这里我将我的代码粘贴在meteorjs中,此代码在html + javascript中完美运行
Template.highcharts.rendered = function() {
var A = [{"name":"cited","drilldown":"DsbsswZFzacLnTPvZ","y":303},{"name":"citing","drilldown":"zKgitWhpv5bZE2wjr","y":218}];
var B = [{"name":"A61K","id":"czZdakWbYzBaq8hu3","data":[["BEIERSDORF AG",1036],["OREAL",583]]},{"name":"A61F","id":"37zqcAeDWCks5xAtL","data":[["BEIERSDORF AG",61],["MINNESOTA MINING & MFG",22]]},{"name":"cited","id":"DsbsswZFzacLnTPvZ","data":[{"name":"A61K","y":1367,"drilldown":"czZdakWbYzBaq8hu3"},{"name":"A61F","y":487,"drilldown":"37zqcAeDWCks5xAtL"}]},{"name":"A61K","id":"HPgny8W554ySyMRpE","data":[["BEIERSDORF AG",587],["OREAL",450]]},{"name":"A61F","id":"AnvkHrMJC5r5rgGeY","data":[["BEIERSDORF AG",64],["KIMBERLY CLARK CO",25]]},{"name":"citing","id":"zKgitWhpv5bZE2wjr","data":[{"name":"A61K","y":959,"drilldown":"HPgny8W554ySyMRpE"},{"name":"A61F","y":296,"drilldown":"AnvkHrMJC5r5rgGeY"}]}];
$("#highcharts").highcharts({
chart: {
type: "pie"
},
title: {text: "Citation Analysis"},
subtitle: {text: "Client: Linto Cheeran"},
drilldown: {
series: B
},
series: [{
data: A, name: "root",
}],
plotOptions: {
series: {
cursor: 'pointer',
dataLabels: {enabled: true},
}
}
});
}
控制台
中没有错误显示请帮帮我
我如何使用meteorjs在高图中进行饼形钻取?
答案 0 :(得分:2)
atmospherejs中提供的Highchart软件包没有下钻模块,因此您必须单独添加drilldown.js。
答案 1 :(得分:0)
一切都像流星的魅力一样。
您可以在meteorpad.com
上进行测试答案 2 :(得分:0)
截至目前,即使是MaazAli在气氛上流行的高级礼包也不包含它。我制作了一个新的包,其中包括MaazAli在大气中流行的高级包装,还有钻取模块。
meteor add clarencel:highcharts