|
@@ -230,7 +230,7 @@ const post = function (url, data, opts) {
|
|
|
}
|
|
|
|
|
|
let dialogcode = jsonres.code === '10020011' || jsonres.code === '10020012'
|
|
|
- if (jsonres.code && dialogcode && (self == top)) {
|
|
|
+ if ((jsonres.code && dialogcode && (self == top)) || jsonres.code === '10020013') {
|
|
|
localStorage.removeItem('accessToken')
|
|
|
delCookie('accessToken')
|
|
|
console.log('token已清除1')
|
|
@@ -252,7 +252,7 @@ const post = function (url, data, opts) {
|
|
|
// } else {
|
|
|
// window.location.href = 'login.html'
|
|
|
// }
|
|
|
- window.location.href = 'login.html'
|
|
|
+ window.parent.window.location.href = 'login.html'
|
|
|
}
|
|
|
});
|
|
|
} else if (jsonres.code && dialogcode && (self != top)) {
|
|
@@ -264,17 +264,6 @@ const post = function (url, data, opts) {
|
|
|
data: jsonres.msg
|
|
|
}
|
|
|
window.parent.postMessage(JSON.stringify(dialogmessage), '*')
|
|
|
- } else if (jsonres.code === '10020013') {
|
|
|
- $.alerModal({
|
|
|
- "message": '登录异常',
|
|
|
- type: "tip",
|
|
|
- time: '1000',
|
|
|
- isFather: true,
|
|
|
- fatherWrapper: $("#mainBox", parent.document)
|
|
|
- });
|
|
|
- setTimeout(() => {
|
|
|
- window.parent.window.location.href = 'login.html'
|
|
|
- }, 1200)
|
|
|
}
|
|
|
resolve({
|
|
|
data: res
|