This commit is contained in:
tanglong 2025-07-25 13:23:50 +08:00
parent 32efbdd94c
commit d050410b4b

View File

@ -21,7 +21,12 @@ namespace YD_AllHeartRates.Api.Services.Impl
}; };
if (data == null || data.Count == 0) if (data == null || data.Count == 0)
return chart; return new ChartDataDto()
{
AxisX = new List<string>() { "8:00", "9:00", "10:00", "11:00", "12:00", "13:00", "14:00", "15:00", "16:00" },
AxisY = new List<int>() { 0, 0, 0, 0, 0, 0, 0, 0, 0 }
};
// 按小时分组计算平均值(四舍五入) // 按小时分组计算平均值(四舍五入)
var hourlyAvg = data var hourlyAvg = data