wechat_jiaxuan/utils/request.js
@@ -1,4 +1,5 @@ import { baseUrl } from "./config" import { wxLoginCustomer } from '../api/index' export function request(options){ let loading = options.loading || '1' // 默认值1显示,否则不显示 @@ -19,9 +20,9 @@ if (res.data.code === 200) { resolve(res.data || true) } else { if(res.data.code && res.data.code == 5112){ wx.navigateTo({ url: '/pages/auth/auth', if(res.data.code == 5111 || res.data.code == 5112){ wx.switchTab({ url: '/pages/index/index', }) } res.data.message && wx.showToast({