Commit 5174faf5 authored by tyyin lan's avatar tyyin lan

fix(首页): 删除会话历史记录后聊天界面未重新开始

parent a4923c6a
...@@ -10,6 +10,7 @@ interface SessionHistoryRecordItem { ...@@ -10,6 +10,7 @@ interface SessionHistoryRecordItem {
const emit = defineEmits<{ const emit = defineEmits<{
getMessageRecordList: [recordId: string] getMessageRecordList: [recordId: string]
createNewSession: []
}>() }>()
const isShowHistoryMenu = defineModel<boolean>({ default: true }) const isShowHistoryMenu = defineModel<boolean>({ default: true })
...@@ -95,6 +96,8 @@ function handleRecordDelete() { ...@@ -95,6 +96,8 @@ function handleRecordDelete() {
isHistoryListEdit.value = false isHistoryListEdit.value = false
emit('createNewSession')
getSessionHistoryRecordList() getSessionHistoryRecordList()
}) })
}) })
......
...@@ -207,6 +207,7 @@ function onGetMessageRecordList(recordId: string) { ...@@ -207,6 +207,7 @@ function onGetMessageRecordList(recordId: string) {
ref="historyMenuSidebarRef" ref="historyMenuSidebarRef"
v-model="isShowHistoryMenu" v-model="isShowHistoryMenu"
@get-message-record-list="onGetMessageRecordList" @get-message-record-list="onGetMessageRecordList"
@create-new-session="onCreateNewSession"
/> />
</div> </div>
......
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