From f8b2ec3593d03dece5cd0d4c82c8f124020fd0f6 Mon Sep 17 00:00:00 2001 From: 2153917462 <2153917462@qq.com> Date: Fri, 25 Apr 2025 14:19:47 +0800 Subject: [PATCH] =?UTF-8?q?=E9=A1=B9=E7=9B=AE=E4=BF=A1=E6=81=AF=E7=AE=A1?= =?UTF-8?q?=E7=90=86=E8=AF=A6=E6=83=85=E5=A4=B4=E9=83=A8=E6=A0=B7=E5=BC=8F?= =?UTF-8?q?=E4=BC=98=E5=8C=96?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/views/manage-add/index.vue | 977 +++++++++++++++++--------------- src/views/manage-info/index.vue | 50 +- 2 files changed, 569 insertions(+), 458 deletions(-) diff --git a/src/views/manage-add/index.vue b/src/views/manage-add/index.vue index 4f6fbe0..1c78e58 100644 --- a/src/views/manage-add/index.vue +++ b/src/views/manage-add/index.vue @@ -1,519 +1,592 @@ \ No newline at end of file + diff --git a/src/views/manage-info/index.vue b/src/views/manage-info/index.vue index 301c930..b494dfe 100644 --- a/src/views/manage-info/index.vue +++ b/src/views/manage-info/index.vue @@ -22,7 +22,7 @@ -
+
= 0; i--) { + const element = document.getElementById(this.sections[i].id); + if (element) { + // 计算元素相对于滚动容器的位置 + const elementPosition = element.offsetTop - container.offsetTop; + + if (elementPosition <= scrollPosition) { + if (this.activeSection !== this.sections[i].id) { + this.activeSection = this.sections[i].id; + } + break; + } + } + } + }, // 子组件的 handleDataUpdate(dataKey, updatedData) { if (dataKey === 'projectOtherInfos' || dataKey === 'wysmxInformations') {