Commit 11e60876 authored by Facius's avatar Facius

返回值data为false的时候取值有问题

parent 7c62f842
......@@ -74,7 +74,7 @@ const install = (Vue, vm) => {
return msg || '请求错误'
}
// 响应拦截,判断状态码是否通过
Vue.prototype.$u.http.interceptor.response = (res) => {
Vue.prototype.$u.http.interceptor.response = (res) => {
let result = res.data || res;
let msg = getMsg(res)
//返回__token__,设置
......@@ -88,7 +88,7 @@ const install = (Vue, vm) => {
// return result;
case 200:
return {
data:result.data || result,
data:typeof(result.data) == 'boolean' ? result.data : result.data || result,
code:code,
message:msg
};
......
......@@ -647,7 +647,7 @@
if (this.submitType == 'orderAccept' || this.submitType == 'orderGan') {
this.$u.api.checkAddCustomer().then((res) => {
if (res.code == 200) {
if(res.data.data === true){
if(res.data === true){
this.handleBtn()
} else {
this.visible = true
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment