From 1e0aa8f63788b1543feb387fea8b0680b6bdb899 Mon Sep 17 00:00:00 2001 From: kevin Date: Sun, 7 Jun 2026 00:27:22 +0800 Subject: [PATCH] =?UTF-8?q?=E5=A2=9E=E5=8A=A0=E6=9C=80=E8=BF=91=E6=8C=89?= =?UTF-8?q?=E9=92=AE?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../src/components/NodeDetailedPage.vue | 16 ++++++++++++---- 1 file changed, 12 insertions(+), 4 deletions(-) diff --git a/meshmap_frontend/src/components/NodeDetailedPage.vue b/meshmap_frontend/src/components/NodeDetailedPage.vue index e1a674d..608c992 100644 --- a/meshmap_frontend/src/components/NodeDetailedPage.vue +++ b/meshmap_frontend/src/components/NodeDetailedPage.vue @@ -270,13 +270,19 @@ async function loadTrajectoryRange() { } } -function applyTodayTrajectory() { - const today = toDateInputValue() - trajectoryStartDate.value = today - trajectoryEndDate.value = today +function applyRecentTrajectory(days: number) { + const end = new Date() + const start = new Date() + start.setDate(end.getDate() - days + 1) + trajectoryStartDate.value = toDateInputValue(start) + trajectoryEndDate.value = toDateInputValue(end) loadTrajectoryRange() } +function applyTodayTrajectory() { + applyRecentTrajectory(1) +} + async function loadInitialMessages() { const response = await getTextMessages(chatPageSize, 0, props.nodeId) messages.value = toChronological(response.items) @@ -639,6 +645,8 @@ onBeforeUnmount(() => { {{ trajectoryLoading ? '查询中...' : '查询轨迹' }} + +

{{ trajectoryError }}

轨迹点较多,仅显示前 {{ maxTrajectoryPoints }} 条,请缩小日期范围。