提交 1a955190 编写于 作者: D DebugIsFalse

fix: 修改请求参数

上级 14a1c31a
export default () => { export default () => {
// 查询主题列表 // 查询主题列表
const getThreadsList = async (c_ids) => { const getThreadsList = async (c_ids) => {
// c_ids => c_id,c_id
let query = c_ids ? `?c_ids=${c_ids}` : '' let query = c_ids ? `?c_ids=${c_ids}` : ''
const { data, error } = await useRequest(`/v1/chat/completion/list${query}`) const { data, error } = await useRequest(`/v1/chat/completion/list${query}`)
if (error.value) { if (error.value) {
......
...@@ -253,7 +253,7 @@ const handleCreateAiTitle = () => { ...@@ -253,7 +253,7 @@ const handleCreateAiTitle = () => {
if (isFirstCreate) { if (isFirstCreate) {
// todo 需要延迟2s获取title // todo 需要延迟2s获取title
setTimeout(async () => { 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) const currentCollection = records.find( item => item.c_id === state.id)
if (currentCollection) { if (currentCollection) {
state.title = currentCollection.title state.title = currentCollection.title
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册