From 603f3d396412e8a61af5d9cc7b9023b1bafefeec Mon Sep 17 00:00:00 2001 From: wikiboss Date: Mon, 21 Sep 2026 11:35:36 +0800 Subject: [PATCH] =?UTF-8?q?fix(mpuniapp):=20=E6=94=AF=E6=8C=81=E6=A0=B9?= =?UTF-8?q?=E8=B7=AF=E5=BE=84=E7=99=BB=E5=BD=95=E9=89=B4=E6=9D=83=E5=88=86?= =?UTF-8?q?=E5=8F=91=E4=B8=8E=E4=B8=9A=E5=8A=A1=E7=AB=AF=E5=88=B0=E7=AB=AF?= =?UTF-8?q?=E6=93=8D=E4=BD=9C=E9=97=AD=E7=8E=AF?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- mpuniapp/App.uvue | 14 +++++++- mpuniapp/pages/owner/card/index.uvue | 5 +++ mpuniapp/pages/owner/leads.uvue | 4 +++ mpuniapp/pages/owner/profile/index.uvue | 39 ++++++++++++++++++++- mpuniapp/pages/owner/profile/useProfile.uts | 2 ++ mpuniapp/pages/owner/radar.uvue | 4 +++ 6 files changed, 66 insertions(+), 2 deletions(-) diff --git a/mpuniapp/App.uvue b/mpuniapp/App.uvue index 3f23e9e..a6a8b5b 100644 --- a/mpuniapp/App.uvue +++ b/mpuniapp/App.uvue @@ -21,7 +21,7 @@ function routeOwnerHome() : void { if (getAuthToken() != '') { uni.switchTab({ - url: '/pages/owner/hall/index' + url: '/pages/owner/card/index' }) return } @@ -34,6 +34,18 @@ // #ifdef APP routeOwnerHome() // #endif + // #ifdef H5 + if (typeof window !== 'undefined') { + const hash = window.location.hash + if (!hash || hash === '#' || hash === '#/' || hash === '') { + if (getAuthToken() != '') { + window.location.hash = '#/pages/owner/card/index' + } else { + window.location.hash = '#/pages/common/login' + } + } + } + // #endif }) onAppShow((res : OnShowOptions) => { diff --git a/mpuniapp/pages/owner/card/index.uvue b/mpuniapp/pages/owner/card/index.uvue index 14f5024..a832507 100644 --- a/mpuniapp/pages/owner/card/index.uvue +++ b/mpuniapp/pages/owner/card/index.uvue @@ -156,6 +156,11 @@ onLoad((options: CardHomePageOptions) => { refreshCards(state); applyQuotaHint(); }); + +onShow(() => { + refreshCards(state); + applyQuotaHint(); +}); diff --git a/mpuniapp/pages/owner/profile/useProfile.uts b/mpuniapp/pages/owner/profile/useProfile.uts index 605daac..ec54be9 100644 --- a/mpuniapp/pages/owner/profile/useProfile.uts +++ b/mpuniapp/pages/owner/profile/useProfile.uts @@ -384,6 +384,8 @@ export function resolveProfileText(key: string): string { return isZh ? '偏好设置' : 'Preferences'; case 'languageLabel': return isZh ? '界面语言' : 'Display Language'; + case 'logout': + return isZh ? '退出登录' : 'Log out'; case 'workspaceSection': return isZh ? '工作台' : 'Workspace'; case 'nfcScan': diff --git a/mpuniapp/pages/owner/radar.uvue b/mpuniapp/pages/owner/radar.uvue index 784891b..9319cef 100644 --- a/mpuniapp/pages/owner/radar.uvue +++ b/mpuniapp/pages/owner/radar.uvue @@ -101,6 +101,10 @@ onLoad((options: RadarPageOptions) => { applyRadarOptions(state, options); refreshTracks(state); }); + +onShow(() => { + refreshTracks(state); +});