|
@@ -229,8 +229,8 @@ const post = function (url, data, opts) {
|
|
|
}
|
|
|
}
|
|
|
|
|
|
- let dialogcode = jsonres.code === '10020011' || jsonres.code === '10020012'
|
|
|
- if (jsonres.code && dialogcode && (self == top)) {
|
|
|
+ let dialogcode = jsonres.code === '10020011' || jsonres.code === '10020012' || jsonres.code === '10020013'
|
|
|
+ if (jsonres.code && dialogcode) {
|
|
|
localStorage.removeItem('accessToken')
|
|
|
console.log('token已清除1')
|
|
|
$.alerModal({
|
|
@@ -251,7 +251,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)) {
|
|
@@ -262,17 +262,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
|