diff --git a/business/jxstore/cms/sync.go b/business/jxstore/cms/sync.go index a984a87d7..b5b1ed796 100644 --- a/business/jxstore/cms/sync.go +++ b/business/jxstore/cms/sync.go @@ -716,19 +716,18 @@ func buildSetFinishHook(task tasksch.ITask, ctx *jxcontext.Context) { } else { globals.SugarLogger.Debugf("同步错误发送钉钉消息失败, authinfo [%v] , [%v]", *authInfo, err) } + } else { + if len(task.GetFailedList()) > 1 { + if time.Now().Hour() >= 20 || time.Now().Hour() < 7 { + downloadURL, _, _ := WirteToExcelBySyncFailed(task) + user, err := dao.GetUserByID(dao.GetDB(), "mobile", "18160030913") + noticeMsg += fmt.Sprintf("[详情点我]%s/billshow/?normal=true&path=%s \n", globals.BackstageHost, downloadURL) + if user != nil && err == nil { + ddmsg.SendUserMessage(dingdingapi.MsgTyeText, user.UserID, "同步错误返回", noticeMsg) + } + } + } } - // else { - // if len(task.GetFailedList()) > 1 { - // if time.Now().Hour() >= 20 || time.Now().Hour() < 7 { - // downloadURL, _, _ := WirteToExcelBySyncFailed(task) - // user, err := dao.GetUserByID(dao.GetDB(), "mobile", "18160030913") - // noticeMsg += fmt.Sprintf("[详情点我]%s/billshow/?normal=true&path=%s \n", globals.BackstageHost, downloadURL) - // if user != nil && err == nil { - // ddmsg.SendUserMessage(dingdingapi.MsgTyeText, user.UserID, "同步错误返回", noticeMsg) - // } - // } - // } - // } }) } diff --git a/business/partner/purchase/jdshop/callback.go b/business/partner/purchase/jdshop/callback.go index 1d5073eef..82a9d28ee 100644 --- a/business/partner/purchase/jdshop/callback.go +++ b/business/partner/purchase/jdshop/callback.go @@ -87,7 +87,7 @@ func SaveJdsOrders(msg *jdshopapi.CallBackResult) (err error) { for _, v := range userIDList { ddmsg.SendUserMessage(dingdingapi.MsgTyeText, v, "京东商城来新订单了!", noticeMsg) } - ddmsg.SendUserMessage(dingdingapi.MsgTyeText, "1439B3E07D3911EA881A525400E86DC0", "京东商城来新订单了!", noticeMsg) + // ddmsg.SendUserMessage(dingdingapi.MsgTyeText, "1439B3E07D3911EA881A525400E86DC0", "京东商城来新订单了!", noticeMsg) return err }