| | |
| | | }) |
| | | this.$message.hideLoading() |
| | | if (code === 0) { |
| | | this.$store.dispatch('sign_add','order') |
| | | this.refreshList() |
| | | } |
| | | } |
| | |
| | | console.log('pay success', res) |
| | | that.$message.showToast('支付成功') |
| | | setTimeout(() => { |
| | | that.$store.dispatch('sign_add','order') |
| | | that.refreshList() |
| | | }, 200) |
| | | }, |
| | |
| | | |
| | | // }, |
| | | case 'cancelOrder': { |
| | | this.$message.showToast('敬请期待') |
| | | }, |
| | | await this.$message.confirm('是否取消订单') |
| | | // 发送请求 |
| | | this.$message.showLoading() |
| | | const { |
| | | code |
| | | } = await this.$http.request('get', '/api/customer/order/cancel', { |
| | | params: { |
| | | id: item.id, |
| | | } |
| | | }) |
| | | this.$message.hideLoading() |
| | | if (code === 0) { |
| | | this.$store.dispatch('sign_add','order') |
| | | this.refreshList() |
| | | } |
| | | } |
| | | break |
| | | default: |
| | | break |
| | | } |