add and fix 一键解冻

This commit is contained in:
2025-12-31 12:40:41 +08:00
parent 5abfd7adbd
commit 193b47893d
14 changed files with 356 additions and 438 deletions

View File

@@ -4,6 +4,8 @@ package service
import (
"encoding/json"
"time"
"tydata-server/app/main/api/internal/config"
"tydata-server/app/main/api/internal/types"
@@ -72,7 +74,8 @@ func (s *AsynqService) SendUnfreezeCommissionTask(commissionID int64) error {
}
options := []asynq.Option{
asynq.MaxRetry(5), // 设置最大重试次数
asynq.ProcessIn(10 * time.Hour), // 10小时后执行
asynq.MaxRetry(5), // 设置最大重试次数
}
task := asynq.NewTask(types.MsgUnfreezeCommission, payloadBytes, options...)