feat(statistics):重构订单统计数据结构以支持多时间范围

- 修改 ZltxOrderStatisticsResponse 结构体以包含最近三天和最近一个月的数据
- 为不同时间范围的统计数据创建嵌套结构体
-保持原有字段如 code 和 error 不变
- 更新数据序列化格式以适应新的嵌套结构
- 确保与现有 API 响应格式向后兼容
This commit is contained in:
wuchao 2025-09-24 11:03:20 +08:00
parent 137ff331fd
commit 2edea5f0fb
1 changed files with 6 additions and 3 deletions

View File

@ -59,7 +59,10 @@ func (z ZltxOrderStatisticsTool) Execute(channel chan entitys.ResponseData, c *w
type ZltxOrderStatisticsResponse struct {
Code int `json:"code"`
Data []ZltxOrderStatisticsData `json:"data"`
Data struct {
RecentThreeDays []ZltxOrderStatisticsData `json:"recentThreeDays"`
RecentOneMonth []ZltxOrderStatisticsData `json:"recentOneMonth"`
} `json:"data"`
Error string `json:"error"`
}