Commit 80bdb7cb authored by 智勇's avatar 智勇

透传后端msg

parent b29cc606
......@@ -43,8 +43,8 @@ service.interceptors.response.use(
duration: 5 * 1000
})
// 50008:非法的token; 50012:其他客户端登录了; 500003:Token 过期了;
if (res.code === 501002 || res.code === 500003) {
// 500003:Token 过期了;
if (res.code === 500003) {
store.dispatch('FedLogOut').then(() => {
location.reload() // 为了重新实例化vue-router对象 避免bug
})
......
......@@ -255,12 +255,20 @@ export default {
}
if (opt.action === 'second_audit') {
secondAudit({ channelOrderNumber: this.order.channelOrderNumber }).then(() => {
secondAudit({ channelOrderNumber: this.order.channelOrderNumber }).then((res) => {
if (res.data) {
this.$notify({
title: '操作成功',
message: res.message,
type: 'success',
duration: 2000
})
} else {
this.$notify({
message: res.message,
type: 'error',
duration: 2000
})
}
this.getOrders()
})
}
......@@ -274,7 +282,7 @@ export default {
}
lendLoan(obj).then(() => {
this.$notify({
title: '操作成功',
message: '操作成功',
type: 'success',
duration: 2000
})
......@@ -285,7 +293,7 @@ export default {
cancelLoan() {
cancelLoan({ channelOrderNumber: this.order.channelOrderNumber }).then(() => {
this.$notify({
title: '关单完毕',
message: '关单完毕',
type: 'success',
duration: 2000
})
......@@ -300,13 +308,13 @@ export default {
approve(this.approveData).then(res => {
if (res.data) {
this.$notify({
title: res.message,
message: res.message,
type: 'success',
duration: 5000
})
} else {
this.$notify({
title: res.message,
message: res.message,
type: 'error',
duration: 5000
})
......
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