fix: scTable getData err处理
This commit is contained in:
parent
6f0a3bf09b
commit
1635262a18
|
@ -238,12 +238,13 @@ export default {
|
|||
this.$emit("dataChange", res, this.tableData);
|
||||
}
|
||||
} catch (error) {
|
||||
console.log(error);
|
||||
this.loading = false;
|
||||
if (error.response && error.response.data) {
|
||||
if (error && error.response && error.response.data) {
|
||||
this.emptyText = error.response.data.err_msg;
|
||||
} else {
|
||||
} else if(error) {
|
||||
this.emptyText = error.statusText || "数据格式错误";
|
||||
}else {
|
||||
this.emptyText = "数据格式错误";
|
||||
}
|
||||
return false;
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue