feat(quota): enhance quota task management with new request structures and processing logic

This commit is contained in:
Chang lue Tsen
2025-09-10 14:53:48 -04:00
parent 83c1c14b01
commit 3f5aac239b
15 changed files with 740 additions and 95 deletions
+7
View File
@@ -144,3 +144,10 @@ func DayDiff(startTime, endTime time.Time) int64 {
duration := endTime.Sub(startTime)
return int64(duration.Hours() / 24) // 转换为整天数
}
// HourDiff 计算两个时间点之间的小时差
func HourDiff(startTime, endTime time.Time) int64 {
// 计算时间差
duration := endTime.Sub(startTime)
return int64(duration.Hours()) // 返回小时数,可能包含小数部分
}