|
@@ -28,8 +28,10 @@ function request(options,hasNoToken) {
|
|
|
_obj.url = baseUrl + _obj.url;
|
|
|
_obj.method = _obj.method.toUpperCase();
|
|
|
_obj.success = function(res) {
|
|
|
- const isCloseUser = res.data.status === '500'&&(res.data.message == 0||res.data.message == -1)
|
|
|
+ console.log(res.data)
|
|
|
+ const isCloseUser = res.data.status == 500&&(res.data.message == 0||res.data.message == -1)
|
|
|
const closeMsg = res.data.message == 0 ? '用户已停用' : '用户已注销'
|
|
|
+ console.log(isCloseUser)
|
|
|
if (_obj.url.indexOf('checkLogin') > -1) {
|
|
|
resolve(res.data);
|
|
|
} else if (res.data.status === '900010' || isCloseUser) {
|
|
@@ -55,6 +57,7 @@ function request(options,hasNoToken) {
|
|
|
}
|
|
|
};
|
|
|
_obj.fail = function(err) {
|
|
|
+ console.log(err)
|
|
|
reject(err);
|
|
|
};
|
|
|
_obj.complete = function() {};
|