From 7c15c84dbaef3494528ae0763e9aea8313b56b48 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?=E5=B0=8F=E8=8E=AB=E5=94=90=E5=B0=BC?= <1431128779@qq.com>
Date: Mon, 28 Oct 2024 18:38:29 +0800
Subject: [PATCH] =?UTF-8?q?update:=20=E8=B0=83=E6=95=B4=E8=8E=B7=E5=8F=96?=
=?UTF-8?q?=E6=A8=A1=E6=8B=9F=E5=8F=82=E6=95=B0=E8=AF=B7=E6=B1=82=E7=AD=96?=
=?UTF-8?q?=E7=95=A5?=
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
---
pages/index/index.vue | 156 +++++++++++++++++++++---------------------
1 file changed, 79 insertions(+), 77 deletions(-)
diff --git a/pages/index/index.vue b/pages/index/index.vue
index a7bc6c0..68881e8 100644
--- a/pages/index/index.vue
+++ b/pages/index/index.vue
@@ -1,84 +1,86 @@
-
+
\ No newline at end of file
+ // 进入检查
+ this.fnCheckShowStarted();
+ }).catch((err) => {
+ uni.switchTab({
+ url: homePagePath
+ });
+ })
+ },
+ methods: {
+ fnCheckShowStarted() {
+ if (!this.configs.appConfig.startConfig.enabled) {
+ uni.switchTab({
+ url: homePagePath
+ });
+ return;
+ }
+
+ // 是否每次都显示启动页
+ if (this.configs.appConfig.startConfig.alwaysShow) {
+ uni.removeStorageSync('APP_HAS_STARTED')
+ uni.redirectTo({
+ url: startPagePath
+ });
+ return;
+ }
+
+ // 只显示一次启动页
+ if (uni.getStorageSync('APP_HAS_STARTED')) {
+ uni.switchTab({
+ url: homePagePath
+ });
+ } else {
+ uni.redirectTo({
+ url: startPagePath
+ });
+ }
+ },
+ async getPostIdByQRCode(key) {
+ const response = await this.$httpApi.v2.getQRCodeInfo(key);
+ if (response) {
+ if (response && response.postId) {
+ return response.postId;
+ }
+ }
+ return null;
+ }
+ }
+};
+