project init

This commit is contained in:
2023-01-28 14:37:45 +08:00
parent fa1176f658
commit 3a134326e7
83 changed files with 1482 additions and 140 deletions

View File

@@ -19,7 +19,8 @@ function initPieChart(canvas, width, height, dpr) {
radius: ['0%', '70%'],
data: [{
value: 55,
name: '数码产品'
name: '数码产品',
id: 1
}, {
value: 20,
name: '零食'
@@ -35,8 +36,10 @@ function initPieChart(canvas, width, height, dpr) {
}]
}]
};
chart.setOption(option);
chart.on('click', 'series.pie', function(param) {
console.log(param.data)
});
return chart;
}