diff --git a/pages/order/OrderDetails/index.vue b/pages/order/OrderDetails/index.vue index 6eea309..04f8827 100644 --- a/pages/order/OrderDetails/index.vue +++ b/pages/order/OrderDetails/index.vue @@ -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(() => { diff --git a/pages/orderAdmin/Statistics/index.vue b/pages/orderAdmin/Statistics/index.vue index 04199c5..fd80bdc 100644 --- a/pages/orderAdmin/Statistics/index.vue +++ b/pages/orderAdmin/Statistics/index.vue @@ -15,7 +15,7 @@ + --> 详细数据 @@ -58,7 +58,7 @@ :end="[2049, 5, 20]" /> - --> + --> @@ -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, @@ -238,11 +241,11 @@ export default { that.time_price = res.data.time; }, error => { - uni.showToast({ - title: error.msg, - icon: "none", - duration: 2000 - });; + uni.showToast({ + 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,15 +403,17 @@ 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', - duration: 2000 - }); + title: + err.msg || err.response.data.msg || err.response.data.message, + icon: "none", + duration: 2000 + }); } ); } @@ -413,7 +423,7 @@ export default {