This commit is contained in:
2025-09-11 14:36:40 +08:00
parent 9ab077ea3b
commit 192959357e
3 changed files with 2 additions and 13 deletions

View File

@@ -28,22 +28,11 @@ $(function () {
async: false, async: false,
dataType: "json", dataType: "json",
url: "/RuYuanZaiYuan/school/preschool/chart", url: "/RuYuanZaiYuan/school/preschool/chart",
success: function (option) { success: function (res) {
option_1_1.series.forEach((seriesItem, index) => { option_1_1.series.forEach((seriesItem, index) => {
seriesItem.tooltip = { valueFormatter: (v) => v + " 万人" }; seriesItem.tooltip = { valueFormatter: (v) => v + " 万人" };
}); });
option_1_1.xAxis[0].data = [ option_1_1.xAxis[0].data = res.xAxis_data;
"2013",
"2016",
"2017",
"2018",
"2019",
"2020",
"2021",
"2022",
"2023",
"2024",
];
myChart.setOption(option_1_1); myChart.setOption(option_1_1);
window.addEventListener("resize", function () { window.addEventListener("resize", function () {
myChart.resize(); myChart.resize();