Bladeren bron

2024-1-19

cmy 1 jaar geleden
bovenliggende
commit
985e84076a
2 gewijzigde bestanden met toevoegingen van 11 en 3 verwijderingen
  1. 8 2
      src/pages/cashier/indexs.vue
  2. 3 1
      src/pages/cashier/servecard.vue

+ 8 - 2
src/pages/cashier/indexs.vue

@@ -1237,7 +1237,7 @@
 					if (this.rechargeVisible) {
 						this.rechargeBalance(payNum);
 					} else {
-						this.orderCreate();
+						this.orderCreate(payNum);
 					}
 				}
 				setTimeout(() => {
@@ -1438,7 +1438,7 @@
 			},
 
 			// 创建订单
-			orderCreate() {
+			orderCreate(payNum) {
 				if (this.payType == "cash") {
 					if (parseFloat(this.priceInfo.payPrice) > parseFloat(this.collection)) {
 						return this.$Message.error("您付款金额不足");
@@ -1451,6 +1451,12 @@
 				} else if (this.storeInfo.product_type == 4) {
 					this.createOrder.new = 1;
 				}
+				if (this.payType == "") {
+					this.createOrder.auth_code=payNum
+				}
+				if (this.payType=='yue') {
+					this.createOrder.userCode=payNum
+				}
 				cashierCreate(this.userInfo.uid, this.createOrder)
 					.then((res) => {
 						let storage = window.localStorage;

+ 3 - 1
src/pages/cashier/servecard.vue

@@ -758,7 +758,9 @@
 				if (this.payType == "") {
 					this.createOrder.auth_code = payNum
 				}
-				console.log(this.createOrder, ' this.createOrder')
+				if (this.payType=='yue') {
+					this.createOrder.userCode=payNum
+				}
 				cashierCreate(this.userInfo.uid, this.createOrder)
 					.then((res) => {
 						console.log(res, '返回res')