This commit is contained in:
邹宗楠
2023-07-18 10:13:42 +08:00
parent 01df953b93
commit fb63c0d831
2 changed files with 6 additions and 0 deletions

View File

@@ -80,6 +80,7 @@ func (c *OrderManager) OnOrderComments(orderCommentList []*model.OrderComment) (
if err == nil || dao.IsNoRowsError(err) {
isNewComment := false
if dao.IsNoRowsError(err) {
globals.SugarLogger.Debugf("========dao.IsNoRowsError= :%s", utils.Format4Output(orderComment, false))
err = nil
isNewComment = true
if orderComment.IsReplied == 0 && time.Now().Sub(orderComment.CommentCreatedAt) < time.Duration(orderComment.ModifyDuration)*time.Hour {
@@ -157,6 +158,9 @@ func (c *OrderManager) OnOrderComments(orderCommentList []*model.OrderComment) (
}
}
}
globals.SugarLogger.Debugf("========comment2= :%s", utils.Format4Output(comment2, false))
globals.SugarLogger.Debugf("========isNewComment= :%s", utils.Format4Output(isNewComment, false))
if err == nil {
if isNewComment {
err = dao.CreateEntity(db, comment2)