From 2abec186104920281020b6b0cc42f2b12da04a18 Mon Sep 17 00:00:00 2001 From: tt-P607 <68868379+tt-P607@users.noreply.github.com> Date: Mon, 1 Sep 2025 13:08:04 +0800 Subject: [PATCH] =?UTF-8?q?fix(qzone):=20=E4=BF=AE=E5=A4=8D=E8=AF=84?= =?UTF-8?q?=E8=AE=BA=E5=9B=9E=E5=A4=8D=E9=80=BB=E8=BE=91=E4=BB=A5=E7=A1=AE?= =?UTF-8?q?=E4=BF=9D=E6=AD=A3=E7=A1=AE=E8=A7=A6=E5=8F=91@=E6=8F=90?= =?UTF-8?q?=E9=86=92?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit - 修改 topicId 格式使用标准评论格式而非针对特定评论 - 在回复内容中明确标示回复对象 "@用户名:" - 优化 paramstr 参数确保触发@提醒机制 - 添加详细注释说明修复目的 --- .../maizone_refactored/services/qzone_service.py | 11 +++++------ 1 file changed, 5 insertions(+), 6 deletions(-) diff --git a/src/plugins/built_in/maizone_refactored/services/qzone_service.py b/src/plugins/built_in/maizone_refactored/services/qzone_service.py index c6e47e676..2a36f822c 100644 --- a/src/plugins/built_in/maizone_refactored/services/qzone_service.py +++ b/src/plugins/built_in/maizone_refactored/services/qzone_service.py @@ -787,14 +787,14 @@ class QZoneService: return False async def _reply(fid, host_qq, target_name, content, comment_tid): - """回复评论""" + """回复评论 - 修复为能正确提醒的回复格式""" try: - # 构造需要的参数 + # 修复回复逻辑:确保能正确提醒被回复的人 data = { - "topicId": f"{host_qq}_{fid}_2", # 主题ID格式修改 + "topicId": f"{host_qq}_{fid}__1", # 使用标准评论格式,而不是针对特定评论 "uin": uin, "hostUin": host_qq, - "content": content, + "content": f"回复@{target_name}:{content}", # 内容中明确标示回复对象 "format": "fs", "plat": "qzone", "source": "ic", @@ -802,8 +802,7 @@ class QZoneService: "ref": "feeds", "richtype": "", "richval": "", - "parent_tid": comment_tid, # 添加父评论ID - "paramstr": f"@{target_name} {content}", + "paramstr": f"@{target_name}", # 确保触发@提醒机制 } # 记录详细的请求参数用于调试