yuxingxing 2 years ago
parent
commit
a31553b0c6

+ 2 - 1
components/payment/index.vue

@@ -161,7 +161,8 @@ export default {
 									icon: 'success'
 								}, () => {
 									that.$emit('onChangeFun', {
-										action: 'pay_complete'
+										action: 'pay_complete',
+										value: paytype
 									});
 								});
 							},

+ 17 - 2
pages/goods/order_confirm/index.vue

@@ -665,9 +665,9 @@ export default {
 			});
 			
 		},
-		payCheck(type) {
+		pay_complete(type) {
+			let that = this
 			this.payType = type;
-			console.log(this.payType);
 			let url = '/pages/goods/order_pay_status/index?order_id=' + this.orderKey + '&msg=' + "支付成功" +
 						'&type=3' + '&totalPrice=' + this.totalPrice
 			uni.showToast({
@@ -680,6 +680,21 @@ export default {
 			}, 1000)
 			// this.SubOrder();
 		},
+		payCheck(type) {
+			this.payType = type;
+			// console.log(this.payType);
+			// let url = '/pages/goods/order_pay_status/index?order_id=' + this.orderKey + '&msg=' + "支付成功" +
+			// 			'&type=3' + '&totalPrice=' + this.totalPrice
+			// uni.showToast({
+			// 	title: that.$t(`支付成功`)
+			// })
+			// setTimeout(res => {
+			// 	uni.redirectTo({
+			// 		url: url
+			// 	})
+			// }, 1000)
+			// this.SubOrder();
+		},
 		/**
 		 * 获取门店列表数据
 		 */

+ 4 - 4
pages/goods/order_list/index.vue

@@ -302,8 +302,8 @@ export default {
 					title: that.$t(`缺少订单号无法取消订单`)
 				});
 			uni.showModal({
-				title: that.$t(`删除订单`),
-				content: that.$t(`确定删除该订单`),
+				title: that.$t(`取消订单`),
+				content: that.$t(`确定取消该订单`),
 				success: function (res) {
 					if (res.confirm) {
 						postUserOrderCancel({ id: order_id })
@@ -342,8 +342,8 @@ export default {
 					title: that.$t(`缺少订单号无法申请退款订单`)
 				});
 			uni.showModal({
-				title: that.$t(`删除订单`),
-				content: that.$t(`确定删除该订单`),
+				title: that.$t(`申请退款`),
+				content: that.$t(`确定申请退款该订单`),
 				success: function (res) {
 					if (res.confirm) {
 						postUserOrderRefund({ id: order_id })

+ 23 - 18
pages/goods/order_pay_status/index.vue

@@ -24,7 +24,7 @@
 				</view>
 				<view class='item acea-row row-between-wrapper'>
 					<view>{{$t(`支付金额`)}}</view>
-					<view class='itemCom'>{{order_pay_info.pay_price}}</view>
+					<view class='itemCom'>{{totalPrice}}</view>
 				</view>
 				<!--失败时加上这个  -->
 				<view class='item acea-row row-between-wrapper'
@@ -112,6 +112,7 @@
 		mixins: [colors],
 		data() {
 			return {
+				totalPrice: 0,
 				loading: false,
 				lotteryLoading: false,
 				orderLottery: false,
@@ -149,6 +150,7 @@
 				url: 1
 			});
 			this.orderId = options.order_id;
+			this.totalPrice = options.totalPrice;
 			this.status = options.status || 0;
 			this.msg = options.msg || '';
 	
@@ -231,24 +233,27 @@
 			 */
 			goOrderDetails: function(e) {
 				let that = this;
-				// #ifdef MP
-				uni.showLoading({
-					title: that.$t(`正在加载中`),
-				})
-				openOrderSubscribe().then(res => {
-					uni.hideLoading();
-					uni.redirectTo({
-						url: '/pages/goods/order_details/index?order_id=' + that.orderId
-					});
-				}).catch(() => {
-					nui.hideLoading();
-				});
-				// #endif
-				// #ifndef MP
 				uni.redirectTo({
-					url: '/pages/goods/order_details/index?order_id=' + that.orderId
-				})
-				// #endif
+					url: '/pages/goods/order_list/index?status=2'
+				});
+				// // #ifdef MP
+				// uni.showLoading({
+				// 	title: that.$t(`正在加载中`),
+				// })
+				// openOrderSubscribe().then(res => {
+				// 	uni.hideLoading();
+				// 	uni.redirectTo({
+				// 		url: '/pages/goods/order_details/index?order_id=' + that.orderId
+				// 	});
+				// }).catch(() => {
+				// 	nui.hideLoading();
+				// });
+				// // #endif
+				// // #ifndef MP
+				// uni.redirectTo({
+				// 	url: '/pages/goods/order_details/index?order_id=' + that.orderId
+				// })
+				// // #endif
 			}
 
 		}