Commit 4bfa2ed0 authored by 智勇's avatar 智勇

审核结果

parent 86f80425
...@@ -42,21 +42,29 @@ service.interceptors.response.use( ...@@ -42,21 +42,29 @@ service.interceptors.response.use(
// 50008:非法的token; 50012:其他客户端登录了; 500003:Token 过期了; // 50008:非法的token; 50012:其他客户端登录了; 500003:Token 过期了;
if (res.code === 501002 || res.code === 500003) { if (res.code === 501002 || res.code === 500003) {
MessageBox.confirm( Message({
'你已被登出,可以取消继续留在该页面,或者重新登录', message: 'token失效,你已被登出',
'确定登出', type: 'warning',
{ duration: 1000
confirmButtonText: '重新登录', })
cancelButtonText: '取消',
type: 'warning'
}
).then(() => {
store.dispatch('FedLogOut').then(() => { store.dispatch('FedLogOut').then(() => {
location.reload() // 为了重新实例化vue-router对象 避免bug location.reload() // 为了重新实例化vue-router对象 避免bug
}) })
}) // MessageBox.confirm(
// '你已被登出,可以取消继续留在该页面,或者重新登录',
// '确定登出',
// {
// confirmButtonText: '重新登录',
// cancelButtonText: '取消',
// type: 'warning'
// }
// ).then(() => {
// store.dispatch('FedLogOut').then(() => {
// location.reload() // 为了重新实例化vue-router对象 避免bug
// })
// })
} }
return Promise.reject('error') // return Promise.reject('error')
} else { } else {
return response.data return response.data
} }
......
...@@ -17,7 +17,6 @@ ...@@ -17,7 +17,6 @@
size="medium" size="medium"
fit fit
highlight-current-row highlight-current-row
style="margin-bottom:20px"
@current-change="handleCurrentChange"> @current-change="handleCurrentChange">
<el-table-column label="ID" type="index" align="center" width="65"/> <el-table-column label="ID" type="index" align="center" width="65"/>
...@@ -227,11 +226,19 @@ export default { ...@@ -227,11 +226,19 @@ export default {
this.approveData.channelOrderNumber = this.order.channelOrderNumber this.approveData.channelOrderNumber = this.order.channelOrderNumber
this.approveData.isPass = data this.approveData.isPass = data
approve(this.approveData).then(res => { approve(this.approveData).then(res => {
if (res.data) {
this.$notify({ this.$notify({
title: '审核完毕', title: res.message,
type: 'success', type: 'success',
duration: 1000 duration: 1000
}) })
} else {
this.$notify({
title: res.message,
type: 'error',
duration: 2000
})
}
this.getOrders() this.getOrders()
}) })
this.dialogFormVisible = false this.dialogFormVisible = false
......
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