From 871dc0d92c86d0ec0e68baf9af94712eb6a11982 Mon Sep 17 00:00:00 2001 From: donqi Date: Mon, 20 Jun 2022 11:06:41 +0800 Subject: [PATCH] =?UTF-8?q?=E9=80=89=E5=AE=8C=E5=B8=88=E5=82=85=E7=B1=BB?= =?UTF-8?q?=E5=88=AB=E4=B9=8B=E5=90=8E=EF=BC=8C=E7=9B=B4=E6=8E=A5=E8=B7=B3?= =?UTF-8?q?=E8=BD=AC=E5=AF=B9=E5=BA=94=E9=A1=B5=E9=9D=A2(1.=E6=9C=8D?= =?UTF-8?q?=E5=8A=A1-=E5=85=A5=E9=A9=BB=EF=BC=8C2.=E5=95=86=E5=93=81-?= =?UTF-8?q?=E4=BE=9B=E5=BA=94=E9=93=BE)?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- components/custom-bar/module-bar.vue | 6 ++++++ pages/index/index-home.vue | 12 ++++++++++-- pages/index/index.vue | 7 +++++-- 3 files changed, 21 insertions(+), 4 deletions(-) diff --git a/components/custom-bar/module-bar.vue b/components/custom-bar/module-bar.vue index b1bbf4e..a5859a7 100644 --- a/components/custom-bar/module-bar.vue +++ b/components/custom-bar/module-bar.vue @@ -51,6 +51,12 @@ uni.$emit('getCurPageInfo', { curPageCode: cur }); + }, + navChangeByCode(curPageCode, isChangeFocus) { + this.curPageCode = isChangeFocus ? curPageCode : this.curPageCode; + uni.$emit('getCurPageInfo', { + curPageCode: curPageCode + }); } } } diff --git a/pages/index/index-home.vue b/pages/index/index-home.vue index b601392..159bb68 100644 --- a/pages/index/index-home.vue +++ b/pages/index/index-home.vue @@ -132,7 +132,8 @@