- use orgCommentContent to decide whether reply in onOrderComment.

This commit is contained in:
gazebo
2018-10-09 15:03:31 +08:00
parent 24d4d8619c
commit 4203dd5b29

View File

@@ -85,7 +85,9 @@ func (c *PurchaseHandler) onOrderComment(msg *jdapi.CallbackOrderMsg) (err error
isNewComment := false
if err == orm.ErrNoRows {
isNewComment = true
c.replyOrderComment(intOrderID, utils.Int64ToStr(utils.MustInterface2Int64(result["storeId"])), score)
if result["orgCommentContent"] == nil {
c.replyOrderComment(intOrderID, utils.Int64ToStr(utils.MustInterface2Int64(result["storeId"])), score)
}
}
if score <= JX_BAD_COMMENTS_MAX_LEVEL || !isNewComment { // 如果是直接非差评,忽略
comment.Createtime = utils.Timestamp2Str(utils.MustInterface2Int64(result["createTime"].(map[string]interface{})["time"]) / 1000)