fix(web): agent‘s tools bugfix

This commit is contained in:
zhaoying
2026-01-14 14:48:17 +08:00
parent fee22f83c9
commit a6e7565919
4 changed files with 11 additions and 2 deletions

View File

@@ -176,6 +176,9 @@ const Agent = forwardRef<AgentRef>((_props, ref) => {
if (response?.knowledge_retrieval?.knowledge_bases?.length) {
getDefaultKnowledgeList(response)
}
if (response?.tools?.length) {
setToolList(response?.tools)
}
}).finally(() => {
setLoading(false)
})

View File

@@ -79,8 +79,6 @@ const ToolList: FC<{ data: ToolOption[]; onUpdate: (config: ToolOption[]) => voi
}
}, [data])
console.log('toolList', toolList)
const handleAddTool = () => {
toolModalRef.current?.handleOpen()
}