|
|
@ -33,7 +33,6 @@ const instance = axios.create({ |
|
|
|
*/ |
|
|
|
instance.interceptors.request.use((config) => { |
|
|
|
const { method, params, url } = config |
|
|
|
|
|
|
|
// 获取当前页面路由
|
|
|
|
let pages = getCurrentPages(); // 获取所有页面栈的实例数组
|
|
|
|
let currentPage = pages[pages.length - 1]; // 获取最后一个页面的实例
|
|
|
@ -45,7 +44,6 @@ instance.interceptors.request.use((config) => { |
|
|
|
currentRoute = currentRoute.slice(0, -'/index'.length); |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
// 附带鉴权的token
|
|
|
|
const headers : any = { |
|
|
|
token: getAccessToken(), |
|
|
|