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
1a1e53ae
authored
May 17, 2024
by
cherishsince
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
【增加】默认选中一个对话
parent
fc315283
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
6 additions
and
2 deletions
+6
-2
src/views/ai/chat/Conversation.vue
+6
-2
No files found.
src/views/ai/chat/Conversation.vue
View file @
1a1e53ae
...
@@ -134,13 +134,17 @@ const getChatConversationList = async () => {
...
@@ -134,13 +134,17 @@ const getChatConversationList = async () => {
return
b
.
updateTime
-
a
.
updateTime
return
b
.
updateTime
-
a
.
updateTime
})
})
conversationList
.
value
=
res
conversationList
.
value
=
res
// 3、没有 任何对话情况
// 3、默认选中
if
(
!
activeId
?.
value
)
{
await
handleConversationClick
(
res
[
0
].
id
)
}
// 4、没有 任何对话情况
if
(
conversationList
.
value
.
length
===
0
)
{
if
(
conversationList
.
value
.
length
===
0
)
{
activeConversationId
.
value
=
null
activeConversationId
.
value
=
null
conversationMap
.
value
=
{}
conversationMap
.
value
=
{}
return
return
}
}
//
4
、对话根据时间分组(置顶、今天、一天前、三天前、七天前、30天前)
//
5
、对话根据时间分组(置顶、今天、一天前、三天前、七天前、30天前)
conversationMap
.
value
=
await
conversationTimeGroup
(
conversationList
.
value
)
conversationMap
.
value
=
await
conversationTimeGroup
(
conversationList
.
value
)
}
}
...
...
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