Commit 99d2bf65 authored by 何金镒's avatar 何金镒

清除会话接口

parent 19dfb9cc
...@@ -206,6 +206,19 @@ public class DifyControllerV2 { ...@@ -206,6 +206,19 @@ public class DifyControllerV2 {
tokenService.cleanConversation(token.getSn()); tokenService.cleanConversation(token.getSn());
} }
@GetMapping("/cleanConversation")
public boolean cleanConversation(@RequestParam(name = "sn") String sn){
QueryWrapper<CDCToken> wrapper = new QueryWrapper<>();
wrapper.eq("sn", sn);
List<CDCToken> list = tokenService.list(wrapper);
if(list.size() != 1){
return false;
}
CDCToken token = list.get(0);
this.cleanConversation(token);
return true;
}
/** /**
* 停止对话 * 停止对话
*/ */
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment