修复消息重发bug
This commit is contained in:
parent
becbe5864d
commit
13872c8979
@ -523,6 +523,10 @@ const fetchRefs = (cur_res_id) => {
|
||||
const sendMessage = () => {
|
||||
const user_input = conv.value.inputText.trim();
|
||||
const dbName = opts.databases.length > 0 ? opts.databases[meta.selectedKB]?.metaname : null;
|
||||
if (isStreaming.value) {
|
||||
message.error('请等待上一条消息处理完成');
|
||||
return
|
||||
}
|
||||
if (user_input) {
|
||||
isStreaming.value = true;
|
||||
appendUserMessage(user_input);
|
||||
@ -530,7 +534,6 @@ const sendMessage = () => {
|
||||
const cur_res_id = conv.value.messages[conv.value.messages.length - 1].id;
|
||||
conv.value.inputText = '';
|
||||
meta.db_name = dbName;
|
||||
|
||||
fetchChatResponse(user_input, cur_res_id)
|
||||
} else {
|
||||
console.log('请输入消息');
|
||||
|
||||
Loading…
Reference in New Issue
Block a user