fix: 待审通知实时回填审核态并重构消息页体验

This commit is contained in:
2026-09-02 01:39:27 +08:00
parent 2e9c42a34c
commit 1c0f7ede55
18 changed files with 1458 additions and 463 deletions

View File

@@ -421,13 +421,18 @@ func (h *Handlers) APIAdminRejectComment(c *gin.Context) {
title = "未知帖子"
}
pid := comment.PostID
_, _ = h.Message.SendSystem(
cid := comment.ID
floor := comment.Floor
_, _ = h.Message.SendSystemWithRefs(
comment.UserID,
"评论未通过审核",
service.FormatCommentRejectContent(title, comment.PostID, comment.Floor, reason),
model.MessageKindReject,
&pid,
nil,
service.SystemNotifyRefs{
PostID: &pid,
CommentID: &cid,
Floor: &floor,
},
)
}
c.JSON(http.StatusOK, gin.H{"message": "已拒绝该评论并通知作者", "status": model.ContentStatusRejected})