From 6dbad69a8d844d64d8d274e47fcd496543fa1746 Mon Sep 17 00:00:00 2001 From: claw_bot Date: Mon, 9 Mar 2026 09:59:41 +0000 Subject: [PATCH] =?UTF-8?q?fix:=20=E4=BF=AE=E5=A4=8D=E8=82=A1=E7=A5=A8?= =?UTF-8?q?=E6=90=9C=E7=B4=A2=E4=B8=8B=E6=8B=89=E4=B8=8D=E6=98=BE=E7=A4=BA?= =?UTF-8?q?=E9=97=AE=E9=A2=98=EF=BC=8C=E5=A2=9E=E5=8A=A0activeSearchIndex?= =?UTF-8?q?=E8=B5=8B=E5=80=BC?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- pages/config/config.vue | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/pages/config/config.vue b/pages/config/config.vue index d40477d..4634b9e 100644 --- a/pages/config/config.vue +++ b/pages/config/config.vue @@ -131,6 +131,9 @@ const searchTimer = ref(null); const searchStock = async (keyword, stockIndex) => { // 防抖 if (searchTimer.value) clearTimeout(searchTimer.value); + // 赋值当前激活的搜索下标 + activeSearchIndex.value = stockIndex; + if (!keyword || keyword.length < 2) { searchResults.value = []; activeSearchIndex.value = -1; @@ -149,6 +152,7 @@ const searchStock = async (keyword, stockIndex) => { } catch (err) { console.error('搜索股票失败:', err); searchResults.value = []; + activeSearchIndex.value = -1; } }, 300); };