diff --git a/src/views/components/HistoryRecord.vue b/src/views/components/HistoryRecord.vue index 9e202b1..8d1c1a6 100644 --- a/src/views/components/HistoryRecord.vue +++ b/src/views/components/HistoryRecord.vue @@ -713,10 +713,12 @@ const closeHistory = () => { const historyData = ref({}); const selectRecord = async (record) => { - if ( - (props.currentType == "AIchat" || props.currentType == "deepNine") && - chatStore.firstAPICall - ) { + if (props.currentType == "AIchat" && chatStore.firstAPICall) { + ElMessage.warning("正在获取回复中,请稍后"); + return; + } + + if (props.currentType == "deepNine" && deepNineStore.firstAPICall) { ElMessage.warning("正在获取回复中,请稍后"); return; } @@ -749,7 +751,7 @@ const selectRecord = async (record) => { dataStore.isFeedback = false; historyData.value = result.data; chatStore.dbqbClickRecord = historyData.value; - deepNineStore.dbqbClickRecord=historyData.value + deepNineStore.dbqbClickRecord = historyData.value; // 构造股票数据对象,保持与现有结构一致 const stockData = { queryText: result.data.keyword, // 使用记录中的keyword字段作为查询文本 @@ -822,6 +824,10 @@ const handleAnnouncementClick = () => { ElMessage.warning("正在获取回复中,请稍后"); return; } + if (props.currentType == "deepNine" && deepNineStore.firstAPICall) { + ElMessage.warning("正在获取回复中,请稍后"); + return; + } emit("showAnnouncement"); }; @@ -831,6 +837,10 @@ const handleFeedbackClick = () => { ElMessage.warning("正在获取回复中,请稍后"); return; } + if (props.currentType == "deepNine" && deepNineStore.firstAPICall) { + ElMessage.warning("正在获取回复中,请稍后"); + return; + } emit("showFeedback"); }; diff --git a/src/views/deepNine.vue b/src/views/deepNine.vue index 937465f..5edefd4 100644 --- a/src/views/deepNine.vue +++ b/src/views/deepNine.vue @@ -712,8 +712,8 @@ const createTypingEffect = (message, content, speed) => { flag: false, content: "系统正在为您努力加载中,请稍后再试", }); - chatStore.isLoading = false; - chatStore.chatInput = false; + homepageChatStore.isLoading = false; + homepageChatStore.deepNineInput = false; emit("enableInput"); if (message.error == "2") { apiStatus.two.isError = true; @@ -723,9 +723,9 @@ const createTypingEffect = (message, content, speed) => { } if (message.end) { homepageChatStore.getUserCount(); - chatStore.isLoading = false; - console.log("打印完毕,接触输入框禁用状态"); - chatStore.chatInput = false; + homepageChatStore.isLoading = false; + console.log("打印完毕,解除输入框禁用状态"); + homepageChatStore.deepNineInput = false; emit("enableInput"); } message.isTyping = false; @@ -810,8 +810,8 @@ const createTypingEffect = (message, content, speed) => { flag: false, content: "系统正在为您努力加载中,请稍后再试", }); - chatStore.isLoading = false; - chatStore.chatInput = false; + homepageChatStore.isLoading = false; + homepageChatStore.deepNineInput = false; emit("enableInput"); if (message.error == "2") { apiStatus.two.isError = true; @@ -840,8 +840,8 @@ const createTypingEffect = (message, content, speed) => { flag: false, content: "系统正在为您努力加载中,请稍后再试", }); - chatStore.isLoading = false; - chatStore.chatInput = false; + homepageChatStore.isLoading = false; + homepageChatStore.deepNineInput = false; emit("enableInput"); if (message.error == "2") { apiStatus.two.isError = true; @@ -1134,8 +1134,8 @@ watch( chatStore.messages.push(aiMsg); - chatStore.isLoading = false; - chatStore.chatInput = false; + homepageChatStore.isLoading = false; + homepageChatStore.deepNineInput = false; chatStore.firstAPICall = false; console.log("历史记录可以点击"); @@ -1157,8 +1157,8 @@ watch( flag: false, content: "系统正在为您努力加载中,请稍后再试", }); - chatStore.isLoading = false; - chatStore.chatInput = false; + homepageChatStore.isLoading = false; + homepageChatStore.deepNineInput = false; chatStore.firstAPICall = false; console.log("历史记录可以点击"); emit("enableInput"); @@ -1497,8 +1497,8 @@ watch( flag: false, content: "系统正在为您努力加载中,请稍后再试", }); - chatStore.isLoading = false; - chatStore.chatInput = false; + homepageChatStore.isLoading = false; + homepageChatStore.deepNineInput = false; emit("enableInput"); } } @@ -1610,8 +1610,8 @@ watch( flag: false, content: "系统正在为您努力加载中,请稍后再试", }); - chatStore.isLoading = false; - chatStore.chatInput = false; + homepageChatStore.isLoading = false; + homepageChatStore.deepNineInput = false; emit("enableInput"); } } @@ -1696,8 +1696,8 @@ watch( flag: false, content: "系统正在为您努力加载中,请稍后再试", }); - chatStore.isLoading = false; - chatStore.chatInput = false; + homepageChatStore.isLoading = false; + homepageChatStore.deepNineInput = false; emit("enableInput"); } } @@ -1868,8 +1868,8 @@ watch( flag: false, content: "数据缺失,请稍后重试", }); - chatStore.isLoading = false; - chatStore.chatInput = false; + homepageChatStore.isLoading = false; + homepageChatStore.deepNineInput = false; chatStore.firstAPICall = false; emit("enableInput"); } @@ -1958,8 +1958,8 @@ watch( isTypingInProgress.value = false; // 4. 重置加载状态 - chatStore.isLoading = false; - chatStore.chatInput = false; + homepageChatStore.isLoading = false; + homepageChatStore.deepNineInput = false; emit("enableInput"); // 在下一个事件循环中清空 dbqbClickRecord diff --git a/src/views/homePage.vue b/src/views/homePage.vue index 064263e..2ed67b4 100644 --- a/src/views/homePage.vue +++ b/src/views/homePage.vue @@ -344,6 +344,7 @@ watch( watch( () => chatStore.deepNineInput, async (newVal) => { + console.log("deepNineInput", chatStore.deepNineInput); if (activeTab.value == "deepNine") { isInputDisabled.value = chatStore.deepNineInput; } @@ -392,7 +393,7 @@ const sendMessage = async () => { if (activeTab.value === "deepNine") { // 禁用输入框 isInputDisabled.value = true; - + chatStore.deepNineInput = true; // 获取深度九大模型的 store const deepNineStore = useDeepNineStore(); @@ -2039,7 +2040,8 @@ onUnmounted(() => {
Token兑换规则
- • 点击右上角"获取Token",即可进入Token兑换页进行金币兑换Token(只能兑换普通Token) + • + 点击右上角"获取Token",即可进入Token兑换页进行金币兑换Token(只能兑换普通Token)
• 金币兑换Token的比例为:1金币=1Token;一经兑换,不予退还