From 012b5ff87c6f148cf68228a5ef869bb4055675f5 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E4=BB=B2=E4=B9=88=E4=BA=86?= Date: Mon, 25 Sep 2023 11:04:57 +0800 Subject: [PATCH] =?UTF-8?q?=E9=A1=B5=E9=9D=A2=E4=BC=98=E5=8C=96?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- manifest.json | 12 +++++------- pages.json | 6 ++++-- pages/index/index.vue | 18 ++++++++++++++++-- 3 files changed, 25 insertions(+), 11 deletions(-) diff --git a/manifest.json b/manifest.json index 07c8553..461b613 100644 --- a/manifest.json +++ b/manifest.json @@ -2,8 +2,8 @@ "name" : "灿能物联", "appid" : "__UNI__88BC25B", "description" : "", - "versionName" : "1.2.8", - "versionCode" : 127, + "versionName" : "1.2.9", + "versionCode" : 129, "transformPx" : false, /* 5+App特有相关 */ "app-plus" : { @@ -16,9 +16,10 @@ "nvueStyleCompiler" : "uni-app", "compilerVersion" : 3, "splashscreen" : { - "alwaysShowBeforeRender" : true, + "useOriginalMsgbox" : true, + "alwaysShowBeforeRender" : false, "waiting" : true, - "autoclose" : true, + "autoclose" : false, "delay" : 0 }, /* 模块配置 */ @@ -107,9 +108,6 @@ "spotlight@3x" : "unpackage/res/icons/120x120.png" } } - }, - "splashscreen" : { - "useOriginalMsgbox" : true } } }, diff --git a/pages.json b/pages.json index 2c21566..2c10601 100644 --- a/pages.json +++ b/pages.json @@ -4,7 +4,8 @@ { "path": "pages/index/index", "style": { - "navigationStyle": "custom" + "navigationStyle": "custom", + "enablePullDownRefresh": true } }, { @@ -480,8 +481,9 @@ "navigationBarTextStyle": "black", "navigationBarTitleText": "灿能电力", "navigationBarBackgroundColor": "#ffffff", - "backgroundColor": "#f3f4f5", + "backgroundColor": "#f3f4f5" // #ifdef H5 + , "navigationStyle": "custom" // #endif }, diff --git a/pages/index/index.vue b/pages/index/index.vue index 247ecf6..8fd6034 100644 --- a/pages/index/index.vue +++ b/pages/index/index.vue @@ -74,6 +74,9 @@ export default { timer: null, } }, + onPullDownRefresh() { + console.log('onPullDownRefresh') + }, computed: { emptyEngineeringName() { if (this.userInfo.authorities === 'tourist') { @@ -141,6 +144,7 @@ export default { this.$refs.device && this.$refs.device.init() }) } + this.$refs.gongCheng?.init() }, getDevCount() { if (!this.select.engineeringId) return @@ -196,7 +200,18 @@ export default { if (!uni.getStorageSync(this.$cacheKey.access_token)) { uni.reLaunch({ url: '/pages/user/login', + success: () => { + // #ifdef APP-PLUS + plus.navigator.closeSplashscreen() + // #endif + }, }) + } else { + setTimeout(() => { + // #ifdef APP-PLUS + plus.navigator.closeSplashscreen() + // #endif + }, 1000) } this.timer = setInterval(this.getDevCount, 3000) // 定时请求 this.store = this.DataSource('/cs-device-boot/EquipmentDelivery/queryEquipmentByProject') @@ -216,14 +231,13 @@ export default { onShow() { this.userInfo = uni.getStorageSync(this.$cacheKey.userInfo) let access_token = uni.getStorageSync(this.$cacheKey.access_token) + console.log(access_token) if (!access_token) { uni.reLaunch({ url: `/pages/user/login`, }) } else { this.init() - console.log(this.$refs.gongCheng); - this.$refs.gongCheng?.init() } }, }