请求500处理
This commit is contained in:
parent
a667473da1
commit
9ac12b7627
|
|
@ -73,6 +73,11 @@ function commonsProcess(showLoading, httpReqCallback,isreturm) {
|
|||
isShowErrorToast = true;
|
||||
return Promise.reject(bodyData); // 跳转到catch函数
|
||||
}
|
||||
if (bodyData.code == 500) {
|
||||
// 提示信息
|
||||
isShowErrorToast = true;
|
||||
return Promise.reject(bodyData); // 跳转到catch函数
|
||||
}
|
||||
if (bodyData.code != 0) {
|
||||
infoBox.showToast(data.message);
|
||||
return;
|
||||
|
|
@ -110,7 +115,7 @@ function commonsProcess(showLoading, httpReqCallback,isreturm) {
|
|||
reject();
|
||||
}
|
||||
if (res.code == 500) {
|
||||
infoBox.showErrorToast(res.message || "服务器异常").then(() => {});
|
||||
infoBox.showErrorToast(res.msg || "服务器异常").then(() => {});
|
||||
reject();
|
||||
}
|
||||
reqFinishFunc(); // 请求完毕的动作
|
||||
|
|
|
|||
Loading…
Reference in New Issue