nft持有查询定时任务

This commit is contained in:
lianghuanjie
2024-12-23 19:59:48 +08:00
parent bbbc750af2
commit a22f73df20
18 changed files with 544 additions and 53 deletions

View File

@@ -31,7 +31,12 @@ func NewJob(svcCtx *svc.ServiceContext) *Job {
c := cron.New()
for _, cr := range cronList {
if cs, ok := cr.(Spec); ok {
_, err = c.AddJob(cs.Spec(), cr)
spec := cs.Spec()
if spec == "" {
logx.Errorw("cron job spec is empty")
continue
}
_, err = c.AddJob(spec, cr)
logx.Must(err)
continue
}