Skip to content
Toggle navigation
P
Projects
G
Groups
S
Snippets
Help
phsl
/
admin
This project
Loading...
Sign in
Toggle navigation
Go to a project
Project
Repository
Issues
0
Merge Requests
0
Pipelines
Wiki
Snippets
Members
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Commit
e896e5bb
authored
May 21, 2024
by
cherishsince
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
【解决todo】AI chat 头部修改模型,不更新问题
parent
939e3790
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
8 additions
and
5 deletions
+8
-5
src/views/ai/chat/index.vue
+8
-5
No files found.
src/views/ai/chat/index.vue
View file @
e896e5bb
...
...
@@ -94,7 +94,6 @@ import {ChatMessageApi, ChatMessageVO} from '@/api/ai/chat/message'
import
{
ChatConversationApi
,
ChatConversationVO
}
from
'@/api/ai/chat/conversation'
import
{
useClipboard
}
from
'@vueuse/core'
import
ChatConversationUpdateForm
from
"@/views/ai/chat/components/ChatConversationUpdateForm.vue"
;
import
{
send
}
from
"vite"
;
const
route
=
useRoute
()
// 路由
const
message
=
useMessage
()
// 消息弹窗
...
...
@@ -381,6 +380,7 @@ const openChatConversationUpdateForm = async () => {
*/
const
handlerTitleSuccess
=
async
()
=>
{
// TODO 需要刷新 对话列表
await
getConversation
(
activeConversationId
.
value
)
}
/**
...
...
@@ -418,9 +418,13 @@ const handlerConversationDelete = async (delConversation: ChatConversationVO) =>
/**
* 对话 - 获取
*/
const
getConversation
=
async
(
id
:
string
)
=>
{
const
getConversation
=
async
(
id
:
string
|
null
)
=>
{
if
(
!
id
)
{
return
}
const
conversation
:
ChatConversationVO
=
await
ChatConversationApi
.
getChatConversationMy
(
id
)
return
conversation
activeConversation
.
value
=
conversation
activeConversationId
.
value
=
conversation
.
id
}
// ============ message ===========
...
...
@@ -435,8 +439,7 @@ onMounted(async () => {
// 设置当前对话 TODO 角色仓库过来的,自带 conversationId 需要选中
if
(
route
.
query
.
conversationId
)
{
const
id
=
route
.
query
.
conversationId
as
string
activeConversationId
.
value
=
id
activeConversation
.
value
=
await
getConversation
(
id
)
as
ChatConversationVO
await
getConversation
(
id
)
}
// 获取列表数据
await
getMessageList
()
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment