From 8e003c1a94d26cc4d477e7aa03593ccb4d7e6c61 Mon Sep 17 00:00:00 2001 From: king <18310653075@163.com> Date: 星期五, 11 十月 2024 17:47:40 +0800 Subject: [PATCH] 2024-10-11 --- src/components/header/index.jsx | 9 ++++++--- 1 files changed, 6 insertions(+), 3 deletions(-) diff --git a/src/components/header/index.jsx b/src/components/header/index.jsx index 307b07e..4ea94db 100644 --- a/src/components/header/index.jsx +++ b/src/components/header/index.jsx @@ -56,7 +56,9 @@ componentDidMount () { // 鑾峰彇绯荤粺鐨勭増鏈俊鎭紝寤舵椂鏌ヨ setTimeout(() => { - Api.getAppVersion() + if (!window.GLOB.$error) { + Api.getAppVersion() + } }, 1000) // sessionStorage 璺ㄩ〉闈㈠叡浜� @@ -109,6 +111,7 @@ setTimeout(() => { sessionStorage.clear() this.props.history.replace('/login') + window.location.reload() }, 2000) }) } @@ -116,7 +119,7 @@ logout = () => { const { dict } = this.state // 閫�鍑虹櫥褰� - let _this = this + let that = this confirm({ title: dict['logout_query'] || '鎮ㄧ‘瀹氳閫�鍑哄悧锛�', content: '', @@ -124,7 +127,7 @@ cancelText: dict['cancel'] || '鍙栨秷', onOk() { sessionStorage.clear() - _this.props.history.replace('/login') + that.props.history.replace('/login') window.location.reload() }, onCancel() {} -- Gitblit v1.8.0