我想在公司的仪表板中使用Highcharts,我正在使用Odoo框架。之前,我已经将另一个Js库与Odoo集成在一起,我遵循相同的步骤。最后,我得到了图表,但没有显示文本,图例或其他任何内容。有什么问题吗?
var chart = new Highcharts.chart('container', {
chart: {
type: 'pyramid'
},
title: {
text: 'Sales pyramid',
x: -50
},
plotOptions: {
series: {
dataLabels: {
enabled: true,
format: '<b>{point.name}</b> ({point.y:,.0f})',
softConnector: true
},
center: ['40%', '50%'],
width: '80%'
}
},
legend: {
enabled: false
},
series: [{
name: 'Unique users',
data: [
['Website visits', 15654],
['Downloads', 4064],
['Requested price list', 1987],
['Invoice sent', 976],
['Finalized', 846]
]
}],
responsive: {
rules: [{
condition: {
maxWidth: 500
},
chartOptions: {
plotOptions: {
series: {
dataLabels: {
inside: true
},
center: ['50%', '50%'],
width: '100%'
}
}
}
}]
}
});
我删除了Highcharts使用的可访问性模块,因为aria-hidden来自该库并且可以正常工作。