diff --git a/business/jxstore/cms/sync.go b/business/jxstore/cms/sync.go index 215e72811..4d4b3087f 100644 --- a/business/jxstore/cms/sync.go +++ b/business/jxstore/cms/sync.go @@ -655,11 +655,11 @@ func buildSetFinishHook(task tasksch.ITask, ctx *jxcontext.Context) { if task.GetErr() != nil { noticeMsg += utils.Format4Output(buildErrMsgJson(task), true) } + } else { + noticeMsg = "您的同步任务执行完成,没有错误返回。" } - if len(task.GetFailedList()) != 0 { - if authInfo, err := ctx.GetV2AuthInfo(); err == nil { - ddmsg.SendUserMessage(dingdingapi.MsgTyeText, authInfo.UserID, "同步错误返回", noticeMsg) - } + if authInfo, err := ctx.GetV2AuthInfo(); err == nil { + ddmsg.SendUserMessage(dingdingapi.MsgTyeText, authInfo.UserID, "同步错误返回", noticeMsg) } } else { if time.Now().Hour() >= 20 || time.Now().Hour() < 7 {