From 1ff1a76a9e0fbc4efb35a2f7a75664005252e4ce Mon Sep 17 00:00:00 2001 From: jerryjzhang Date: Sat, 25 Apr 2026 20:24:46 +0800 Subject: [PATCH] =?UTF-8?q?feat(chat):=20=E6=B7=BB=E5=8A=A0=E9=97=AE?= =?UTF-8?q?=E9=A2=98ID=E5=88=A0=E9=99=A4=E8=A7=A3=E6=9E=90=E4=BF=A1?= =?UTF-8?q?=E6=81=AF=E5=8A=9F=E8=83=BD?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit - 在ChatParseMapper接口中新增deleteByQuestionId方法 - 实现按问题ID删除聊天解析数据的功能 - 在XML映射文件中添加对应的DELETE SQL语句 --- .../chat/server/persistence/mapper/ChatParseMapper.java | 2 ++ chat/server/src/main/resources/mapper/ChatParseMapper.xml | 5 +++++ 2 files changed, 7 insertions(+) diff --git a/chat/server/src/main/java/com/tencent/supersonic/chat/server/persistence/mapper/ChatParseMapper.java b/chat/server/src/main/java/com/tencent/supersonic/chat/server/persistence/mapper/ChatParseMapper.java index c733c5abb..282f3b789 100644 --- a/chat/server/src/main/java/com/tencent/supersonic/chat/server/persistence/mapper/ChatParseMapper.java +++ b/chat/server/src/main/java/com/tencent/supersonic/chat/server/persistence/mapper/ChatParseMapper.java @@ -18,4 +18,6 @@ public interface ChatParseMapper { List getParseInfoList(List questionIds); List getContextualParseInfo(Integer chatId); + + int deleteByQuestionId(Long questionId); } diff --git a/chat/server/src/main/resources/mapper/ChatParseMapper.xml b/chat/server/src/main/resources/mapper/ChatParseMapper.xml index 8e1e5336a..8cb2cf8e8 100644 --- a/chat/server/src/main/resources/mapper/ChatParseMapper.xml +++ b/chat/server/src/main/resources/mapper/ChatParseMapper.xml @@ -52,4 +52,9 @@ where chat_id = #{chatId} order by question_id desc limit 10 + + delete from s2_chat_parse + where question_id = #{questionId} + +