diff --git a/src/views/AIchat.vue b/src/views/AIchat.vue index 6b5025b..876fd81 100644 --- a/src/views/AIchat.vue +++ b/src/views/AIchat.vue @@ -2467,7 +2467,7 @@ watch( chatStore.messages.push({ sender: "user", timestamp: clickRecord.value.createdTime, - content: clickRecord.value.stockName+'('+clickRecord.value.stockCode+')', + content: clickRecord.value.keyword, audioArray: [ clickRecord.value.wokeFlowData.One.url, clickRecord.value.wokeFlowData.Two.url, @@ -4477,7 +4477,7 @@ onUnmounted(() => {
-
+
{{ moment(msg.timestamp).format("YYYY-MM-DD HH:mm:ss") }}
diff --git a/src/views/components/HistoryRecord.vue b/src/views/components/HistoryRecord.vue index e0d0cbd..50d31ef 100644 --- a/src/views/components/HistoryRecord.vue +++ b/src/views/components/HistoryRecord.vue @@ -78,7 +78,7 @@
-
+
{{ history.name }}
-
+
{{ history.name }}
{ }); if (result && result.data) { + if (props.isMobile) { + // 如果手机,收起历史记录 + isCollapsed.value = true; + if (props.currentType == "AIchat") { + chatStore.aiChatCall = false; + } else if (props.currentType == "AiEmotion") { + chatStore.aiEmotionCall = false; + } + } historyData.value = result.data; chatStore.dbqbClickRecord = historyData.value; // 构造股票数据对象,保持与现有结构一致 @@ -908,6 +917,7 @@ onMounted(() => { width: 100%; /* padding: 20px; */ overflow: hidden; + min-height: 0; } .head-container { diff --git a/src/views/homePage.vue b/src/views/homePage.vue index fee536e..82d85e4 100644 --- a/src/views/homePage.vue +++ b/src/views/homePage.vue @@ -256,7 +256,6 @@ const sendMessage = async () => { { sender: "user", content: messageContent, - timestamp: new Date().toISOString(), audioArray: [], audioStatus: false, }, @@ -596,6 +595,11 @@ const onBlur = function () { let touchmoveHandlerRef = null; const touchmoveHandler = (e) => { if (!dataStore.isFeedback) { + if (historyRecordRef) { + if (!historyRecordRef.value.isCollapsed) { + return; + } + } // 判断触摸目标是否在可滚动区域内 const isScrollableArea = e.target.closest(".tab-content");