Commit 442c94cc authored by 熊成伟's avatar 熊成伟

debug

parent 3446cf24
Pipeline #15282 failed with stages
in 36 seconds
This diff is collapsed.
...@@ -52,7 +52,7 @@ export const createAPI = (baseURL) => { ...@@ -52,7 +52,7 @@ export const createAPI = (baseURL) => {
// console.log(response) // console.log(response)
if (!response || !response.data) { if (!response || !response.data) {
// response.code === 'idt-core-505' && (window.location.href = '/login') response.code === 'idt-core-505' && (window.location.href = '/login')
console.log('response出错, 无返回数据!', response); return false; console.log('response出错, 无返回数据!', response); return false;
}; };
if (response.data && response.data.errorMessage) { if (response.data && response.data.errorMessage) {
...@@ -66,6 +66,9 @@ export const createAPI = (baseURL) => { ...@@ -66,6 +66,9 @@ export const createAPI = (baseURL) => {
} }
localStorage.setItem("token", response.data.token); localStorage.setItem("token", response.data.token);
} }
if (response && response.data && response.data.leftOperateBar) {
localStorage.setItem("menu", JSON.stringify(response.data.leftOperateBar));
}
if (response.data) { if (response.data) {
return response.data; return response.data;
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment