tanyanfei 2 years ago
parent
commit
6b3ac96d91
1 changed files with 5 additions and 3 deletions
  1. 5 3
      utils/api.js

+ 5 - 3
utils/api.js

@@ -36,9 +36,11 @@ function request(method, url, data) {
             } else if (res.data.code == 403) {
               //未登录
               reject(403)
-              wx.navigateTo({
-                url: '../login/user',
-              })
+              setTimeout(()=>{
+                wx.navigateTo({
+                  url: '../login/user',
+                })
+              },100)
             }else{
               wx.hideNavigationBarLoading()
               wx.hideLoading()