|
@@ -34,7 +34,7 @@
|
|
|
身份证 {{i.touristCode|handle(3)}}
|
|
|
</view>
|
|
|
</view>
|
|
|
- <u-icon name="minus-circle" size="36" color="#FEA400" @tap="jian(item)"
|
|
|
+ <u-icon name="minus-circle" size="36" color="#FEA400" @tap="jian(index)"
|
|
|
v-if="i.remark!='book'"></u-icon>
|
|
|
</view>
|
|
|
</view>
|
|
@@ -84,9 +84,6 @@
|
|
|
this.boatNo = opt.boatNo || '';
|
|
|
this.getOrderInfo();
|
|
|
this.getTypes();
|
|
|
- console.log(tuomin())
|
|
|
- //获取上次核销缓存
|
|
|
-
|
|
|
},
|
|
|
filters: {
|
|
|
handle(val, type) {
|
|
@@ -113,7 +110,6 @@
|
|
|
merchantId: this.merchantId,
|
|
|
boatNo: this.boatNo
|
|
|
}).then(res => {
|
|
|
- console.log(res.data)
|
|
|
if (res.data.code == 0) {
|
|
|
this.orderInfo = res.data.data;
|
|
|
this.keyName = this.orderInfo.playDate + this.orderInfo.playTime + this.boatNo;
|
|
@@ -146,25 +142,21 @@
|
|
|
sendData.merchantId = this.orderInfo.merchantId;
|
|
|
sendData.orderType = this.orderInfo.orderType;
|
|
|
sendData.type = type;
|
|
|
- sendData.writeOffCode = result;
|
|
|
- console.log(sendData)
|
|
|
-
|
|
|
+ sendData.boatNo = this.boatNo;
|
|
|
+ if(type==0) sendData.writeOffCode = result;
|
|
|
+ else if(type==1){
|
|
|
+ sendData.touristCode = encrypt(result);
|
|
|
+ sendData.touristName = name;
|
|
|
+ }
|
|
|
this.$api.post('/scenic/api/order/scanCode', sendData).then(res => {
|
|
|
- console.log(res.data)
|
|
|
if (res.data.code == 0) {
|
|
|
if (this.data.findIndex((item) => {
|
|
|
return item.touristCode == res.data.data.touristCode
|
|
|
}) > -1) {
|
|
|
this.$showToast('该核验码已扫')
|
|
|
} else {
|
|
|
- // "id": 0,
|
|
|
- // "orderCode": "",
|
|
|
- // "remark": "",
|
|
|
- // "touristCode": "",
|
|
|
- // "touristName": ""
|
|
|
-
|
|
|
- res.data.data.touristCode = encrypt(res.data.data.touristCode);
|
|
|
- res.data.data.touristName = encrypt(res.data.data.touristName)
|
|
|
+ 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,
|
|
@@ -208,6 +200,9 @@
|
|
|
}
|
|
|
})
|
|
|
uni.removeStorageSync(this.keyName);
|
|
|
+ },
|
|
|
+ jian(index){
|
|
|
+ if(this.data.length>index) this.data.splice(index,1);
|
|
|
}
|
|
|
}
|
|
|
}
|