修改取消订单报错的问题
This commit is contained in:
@ -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(() => {
|
||||
|
@ -161,7 +161,10 @@ export default {
|
||||
},
|
||||
animationDuration: 2000
|
||||
},
|
||||
value: [[year, month, day - 1], [year, month, day]],
|
||||
value: [
|
||||
[year, month, day - 1],
|
||||
[year, month, day]
|
||||
],
|
||||
isrange: true,
|
||||
weekSwitch: false,
|
||||
ismulti: false,
|
||||
@ -242,7 +245,7 @@ export default {
|
||||
title: error.msg,
|
||||
icon: "none",
|
||||
duration: 2000
|
||||
});;
|
||||
});
|
||||
}
|
||||
);
|
||||
},
|
||||
@ -285,7 +288,10 @@ export default {
|
||||
}
|
||||
},
|
||||
clickSomeThing(data) {
|
||||
this.value = [[2019, 4, 1], [2019, 4, 8]];
|
||||
this.value = [
|
||||
[2019, 4, 1],
|
||||
[2019, 4, 8]
|
||||
];
|
||||
},
|
||||
setMonthRange() {
|
||||
this.monthRange = this.monthRange.length ? [] : ["2019-4", "2020-1"];
|
||||
@ -316,14 +322,20 @@ export default {
|
||||
multiMode() {
|
||||
this.ismulti = true;
|
||||
this.isrange = false;
|
||||
this.value = [[year, month, 16], [year, month, 18]];
|
||||
this.value = [
|
||||
[year, month, 16],
|
||||
[year, month, 18]
|
||||
];
|
||||
this.handelRenderValues();
|
||||
// this.$refs.calendar.renderer(year, month);
|
||||
},
|
||||
rangeMode() {
|
||||
this.ismulti = false;
|
||||
this.isrange = true;
|
||||
this.value = [[year, month, 16], [year, month, 22]];
|
||||
this.value = [
|
||||
[year, month, 16],
|
||||
[year, month, 22]
|
||||
];
|
||||
this.handelRenderValues();
|
||||
// this.$refs.calendar.renderer(year, month);
|
||||
},
|
||||
@ -334,14 +346,10 @@ export default {
|
||||
this.handelRenderValues();
|
||||
// this.$refs.calendar.renderer(year, month);
|
||||
},
|
||||
selectMonth(month, year) {
|
||||
},
|
||||
prev(y, m, w) {
|
||||
},
|
||||
next(year, month, week) {
|
||||
},
|
||||
selectYear(year) {
|
||||
},
|
||||
selectMonth(month, year) {},
|
||||
prev(y, m, w) {},
|
||||
next(year, month, week) {},
|
||||
selectYear(year) {},
|
||||
setToday() {
|
||||
// this.$refs.calendar.setToday();
|
||||
},
|
||||
@ -395,13 +403,15 @@ export default {
|
||||
res => {
|
||||
that.loading = false;
|
||||
that.loaded = res.data.length < that.filter.limit;
|
||||
that.list.push.apply(that.list, res.data);
|
||||
// that.list.push.apply(that.list, res.data);
|
||||
that.list = res.data;
|
||||
that.filter.page = that.filter.page + 1;
|
||||
},
|
||||
err => {
|
||||
uni.showToast({
|
||||
title: err.msg || err.response.data.msg|| err.response.data.message,
|
||||
icon: 'none',
|
||||
title:
|
||||
err.msg || err.response.data.msg || err.response.data.message,
|
||||
icon: "none",
|
||||
duration: 2000
|
||||
});
|
||||
}
|
||||
|
Reference in New Issue
Block a user