feat:【antd】【crm】优化 statistics 的整体代码

This commit is contained in:
YunaiV
2025-09-30 13:16:52 +08:00
parent 0d1901abdb
commit 2d5f24c626
8 changed files with 28 additions and 17 deletions

View File

@@ -38,8 +38,8 @@ const [Grid, gridApi] = useVbenVxeGrid({
ajax: {
query: async (_, formValues) => {
const res = await getDatas(activeTabName.value, formValues);
renderLeftEcharts(getChartOptions(activeTabName.value, res).left);
renderRightEcharts(getChartOptions(activeTabName.value, res).right);
await renderLeftEcharts(getChartOptions(activeTabName.value, res).left);
await renderRightEcharts(getChartOptions(activeTabName.value, res).right);
return res;
},
},
@@ -54,12 +54,13 @@ const [Grid, gridApi] = useVbenVxeGrid({
} as VxeTableGridOptions<CrmStatisticsCustomerApi.CustomerSummaryByUser>,
});
/** tab 切换 */
async function handleTabChange(key: any) {
activeTabName.value = key;
gridApi.setGridOptions({
columns: useGridColumns(key),
});
gridApi.reload();
await gridApi.reload();
}
</script>