Authored by 李奇

BLK老版本没有sessionKey导致的401提示升级

... ... @@ -11,7 +11,7 @@ const isTest = process.env.NODE_ENV === 'test';
module.exports = {
app: 'h5',
appVersion: '6.1.0', // 调用api的版本
appVersion: '5.6.0', // 调用api的版本
port: 6004,
siteUrl: '//m.yohoblk.com',
signExtend: {
... ...
... ... @@ -6,12 +6,18 @@
import $ from 'jquery';
import cookie from 'yoho-cookie';
import yoho from 'yoho';
// 初始化
import tip from 'common/tip';
// 注册ajaxError处理服务端401状态
$(document).ajaxError((event, xhr) => {
if (xhr.status === 401) {
if (!cookie.get('app_version')) {
tip({
txt: '请升级APP至最新版',
delay: 60 * 1000
});
return;
}
cookie.remove('_UID');
cookie.remove('_TOKEN');
... ...