From 552d58defc01b580f659b0c660fb8e17d01eb22c Mon Sep 17 00:00:00 2001 From: zhenyuWang <13641039885@163.com> Date: Wed, 4 Sep 2024 21:35:46 +0800 Subject: [PATCH] =?UTF-8?q?refactor(dialogPage):=20=E8=B0=83=E6=95=B4?= =?UTF-8?q?=E6=96=B9=E6=B3=95=E5=91=BD=E5=90=8D?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- pages/API/dialog-page/dialog-1.uvue | 6 +++--- pages/API/dialog-page/dialog-page.uvue | 4 ++-- 2 files changed, 5 insertions(+), 5 deletions(-) diff --git a/pages/API/dialog-page/dialog-1.uvue b/pages/API/dialog-page/dialog-1.uvue index 0b9d79a5..d62e6bc6 100644 --- a/pages/API/dialog-page/dialog-1.uvue +++ b/pages/API/dialog-page/dialog-1.uvue @@ -43,9 +43,9 @@ // 自动化测试 setLifeCycleNum(state.lifeCycleNum + 1) const currentPages = getCurrentPages() - const parentPage = this.$getParentPage()! - const grandParentPage = parentPage.$getParentPage() - const dialogPages = parentPage.$getDialogPages() + const parentPage = this.getParentPage()! + const grandParentPage = parentPage.getParentPage() + const dialogPages = parentPage.getDialogPages() const dialogPage = this.$dialogPage! if ( currentPages.length == 1 && diff --git a/pages/API/dialog-page/dialog-page.uvue b/pages/API/dialog-page/dialog-page.uvue index 4d687e2d..812a1a87 100644 --- a/pages/API/dialog-page/dialog-page.uvue +++ b/pages/API/dialog-page/dialog-page.uvue @@ -73,7 +73,7 @@ console.log('dialogPage1 be triggered fnOnce', options) setLifeCycleNum(state.lifeCycleNum + 1) } - dialogPage.on('fn1', fn1) + dialogPage.on('fn1', fn1) dialogPage.on('fn1', fn11) dialogPage.on('fn2', fn2) dialogPage.once('fnOnce', fnOnce) @@ -165,7 +165,7 @@ }) }, closeSpecifiedDialog(index: number) { - const dialogPages = this.$getDialogPages() + const dialogPages = this.getDialogPages() uni.closeDialogPage({ dialogPage: dialogPages[index], success(res) { -- GitLab