htc 10 months ago
parent
commit
071aadd266
2 changed files with 8 additions and 26 deletions
  1. 4 13
      pagesHouse/Verification/check.vue
  2. 4 13
      pagesHouse/Verification/checkApp.vue

+ 4 - 13
pagesHouse/Verification/check.vue

@@ -87,7 +87,7 @@
 		},
 		filters: {
 			handle(val, type) {
-				return tuomin(decrypt(val), type)
+				return tuomin(val, type);
 			}
 		},
 		methods: {
@@ -119,7 +119,7 @@
 					}
 				})
 			},
-			scanCode(type) {
+			scanCode(type) {
 				uni.scanCode({
 					onlyFromCamera: true,
 					success: (res) => {
@@ -146,7 +146,7 @@
 				if(type==0) sendData.writeOffCode = result;
 				else if(type==1){
 					sendData.touristCode = encrypt(result);
-					sendData.touristName = name;
+					sendData.touristName = encrypt(name);
 				} 
 				this.$api.post('/scenic/api/order/scanCode', sendData).then(res => {
 					if (res.data.code == 0) {
@@ -155,16 +155,7 @@
 							}) > -1) {
 							this.$showToast('该核验码已扫')
 						} else {
-							res.data.data.touristCode = res.data.data.touristCode;
-							res.data.data.touristName = res.data.data.touristName
-							let json = {
-								id: res.data.data.id,
-								orderCode:res.data.data.orderCode,
-								remark:res.data.data.remark,
-								touristCode:res.data.data.touristCode,
-								touristName: res.data.data.touristName
-							}
-							this.data.push(json)
+							this.data.push(res.data.data);
 						}
 					} else {
 						this.$showToast(res.data.msg)

+ 4 - 13
pagesHouse/Verification/checkApp.vue

@@ -102,7 +102,7 @@
 		},
 		filters: {
 			handle(val, type) {
-				return tuomin(decrypt(val), type)
+				return tuomin(val, type);
 			}
 		},
 		methods: {
@@ -184,7 +184,7 @@
 				if(type==0) sendData.writeOffCode = result;
 				else if(type==1){
 					sendData.touristCode = encrypt(result);
-					sendData.touristName = name;
+					sendData.touristName = encrypt(name);
 				} 
 
 				this.$api.post('/scenic/api/order/scanCode', sendData).then(res => {
@@ -195,17 +195,8 @@
 								let mg = '该核验码已扫';
 								if(type==1) mg = '该身份证已扫';
 							this.$showToast(mg);
-						} else {
-							res.data.data.touristCode = res.data.data.touristCode;
-							res.data.data.touristName = res.data.data.touristName
-							let json = {
-								id: res.data.data.id,
-								orderCode:res.data.data.orderCode,
-								remark:res.data.data.remark,
-								touristCode:res.data.data.touristCode,
-								touristName: res.data.data.touristName
-							}
-							this.data.push(json)
+						} else {
+							this.data.push(res.data.data);
 						}
 						if(type==1) lcReader.cancelCycle();//关闭循环读卡
 					} else {