From 4e4157286f617f75ea72296e62da3606f44504d2 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?TOP=E7=B3=AF=E7=B1=B3?= <1130395124@qq.com> Date: Mon, 3 Apr 2023 11:01:04 +0800 Subject: [PATCH] =?UTF-8?q?=E4=BC=98=E5=8C=96=E8=BF=94=E5=9B=9E=E4=BB=A3?= =?UTF-8?q?=E7=A0=81?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/components/layout/layout.vue | 7 +------ 1 file changed, 1 insertion(+), 6 deletions(-) diff --git a/src/components/layout/layout.vue b/src/components/layout/layout.vue index 75bb09b..86eb6a0 100644 --- a/src/components/layout/layout.vue +++ b/src/components/layout/layout.vue @@ -44,7 +44,6 @@ export default { headerHeight: 0, statusBarHeight: 0, bodyPaddingTop: 0, - backType: "back", }; }, components: { @@ -107,10 +106,6 @@ export default { if (this.showHeader) { this.bodyPaddingTop = safePaddingTop; } - const pages = getCurrentPages(); - if (pages.length < 2) { - this.backType = "home"; - } }, mounted() {}, methods: { @@ -118,7 +113,7 @@ export default { if (this.customBtn) { this.$emit("onClickBtn"); } else { - if (this.backType == "home") { + if (getCurrentPages().length < 2) { uni.switchTab({ url: "/pages/index/index", });