修改取消订单报错的问题

This commit is contained in:
gaoxs
2020-05-26 19:07:10 +08:00
parent a5cfc0b8e7
commit b908a4855e
2 changed files with 46 additions and 30 deletions

View File

@ -542,15 +542,21 @@ export default {
}
},
goBack() {
if (last.name === "MyOrder") return this.$yrouter.back();
else
return this.$yrouter.replace({
path: "/order/list/"
if (this.name === "MyOrder") {
this.$yrouter.back();
return;
} else {
console.log(this)
this.$yrouter.replace({
path: "/pages/order/MyOrder/index"
});
return;
}
},
cancelOrder() {
cancelOrderHandle(this.orderInfo.orderId)
.then(() => {
setTimeout(() => this.goBack(), 300);
})
.catch(() => {