Commit 8b3e957a authored by tyyin lan's avatar tyyin lan

chore(首页): 历史记录优化

parent 9d58a803
......@@ -24,5 +24,7 @@ export function fetchHistoryRecordDelete<T>(recordIdList: string[]) {
}
export function fetchMessageRecordList<T>(dialogueId: string) {
return request.post<T>(`/agentApplicationRest/getDialogueContext.json?dialogueId=${dialogueId}`)
return request.post<T>(`/agentApplicationRest/getDialogueContext.json?dialogueId=${dialogueId}`, null, {
timeout: 12000,
})
}
......@@ -50,7 +50,7 @@ function getSessionHistoryRecordList(isCreateNewSessionCheck = false) {
isCreateNewSessionCheck &&
props.currentSessionId &&
(sessionHistoryRecordList.value.length === 0 ||
sessionHistoryRecordList.value.find((item) => item.dialogsId !== props.currentSessionId))
sessionHistoryRecordList.value.every((item) => item.dialogsId !== props.currentSessionId))
) {
emit('createNewSession')
}
......
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