diff --git a/composables/useLibraryRequest.js b/composables/useLibraryRequest.js index d1800ae9fa8641bc07b472714b00de4c3ec2d19d..ef0f01e4a8e7157f1f7a0502c157586a07124c8b 100644 --- a/composables/useLibraryRequest.js +++ b/composables/useLibraryRequest.js @@ -1,6 +1,7 @@ export default () => { // 查询主题列表 const getThreadsList = async (c_ids) => { + // c_ids => c_id,c_id let query = c_ids ? `?c_ids=${c_ids}` : '' const { data, error } = await useRequest(`/v1/chat/completion/list${query}`) if (error.value) { diff --git a/pages/search/[id].vue b/pages/search/[id].vue index 8c99795f9ceb505bb0b22917f5d97fe6864a8563..402b82e993be17969c09e0689f0fe5ad3b58928d 100644 --- a/pages/search/[id].vue +++ b/pages/search/[id].vue @@ -253,7 +253,7 @@ const handleCreateAiTitle = () => { if (isFirstCreate) { // todo 需要延迟2s获取title setTimeout(async () => { - const records = await getThreadsList(JSON.stringify([state.id])) + const records = await getThreadsList(state.id) const currentCollection = records.find( item => item.c_id === state.id) if (currentCollection) { state.title = currentCollection.title