浏览代码

2024-1-19

cmy 1 年之前
父节点
当前提交
985e84076a
共有 2 个文件被更改,包括 11 次插入3 次删除
  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) {
 					if (this.rechargeVisible) {
 						this.rechargeBalance(payNum);
 						this.rechargeBalance(payNum);
 					} else {
 					} else {
-						this.orderCreate();
+						this.orderCreate(payNum);
 					}
 					}
 				}
 				}
 				setTimeout(() => {
 				setTimeout(() => {
@@ -1438,7 +1438,7 @@
 			},
 			},
 
 
 			// 创建订单
 			// 创建订单
-			orderCreate() {
+			orderCreate(payNum) {
 				if (this.payType == "cash") {
 				if (this.payType == "cash") {
 					if (parseFloat(this.priceInfo.payPrice) > parseFloat(this.collection)) {
 					if (parseFloat(this.priceInfo.payPrice) > parseFloat(this.collection)) {
 						return this.$Message.error("您付款金额不足");
 						return this.$Message.error("您付款金额不足");
@@ -1451,6 +1451,12 @@
 				} else if (this.storeInfo.product_type == 4) {
 				} else if (this.storeInfo.product_type == 4) {
 					this.createOrder.new = 1;
 					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)
 				cashierCreate(this.userInfo.uid, this.createOrder)
 					.then((res) => {
 					.then((res) => {
 						let storage = window.localStorage;
 						let storage = window.localStorage;

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

@@ -758,7 +758,9 @@
 				if (this.payType == "") {
 				if (this.payType == "") {
 					this.createOrder.auth_code = payNum
 					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)
 				cashierCreate(this.userInfo.uid, this.createOrder)
 					.then((res) => {
 					.then((res) => {
 						console.log(res, '返回res')
 						console.log(res, '返回res')