|
@@ -91,6 +91,7 @@
|
|
|
},
|
|
|
scanCode(type) {
|
|
|
uni.scanCode({
|
|
|
+ onlyFromCamera:true,
|
|
|
success: (res) => {
|
|
|
console.log('扫码结果:' + res.result);
|
|
|
// 扫码成功后的操作,例如:
|
|
@@ -111,7 +112,7 @@
|
|
|
sendData.merchantId=this.orderInfo.merchantId;
|
|
|
sendData.orderType=this.orderInfo.orderType;
|
|
|
sendData.type=type;
|
|
|
- sendData.writeOffCode="70";
|
|
|
+ sendData.writeOffCode=result;
|
|
|
console.log(sendData)
|
|
|
|
|
|
this.$api.post('/scenic/order/scanCode',sendData).then(res=>{
|
|
@@ -127,7 +128,8 @@
|
|
|
}else{
|
|
|
this.data.push(res.data.data)
|
|
|
}
|
|
|
-
|
|
|
+ }else{
|
|
|
+ this.$showToast(res.data.msg)
|
|
|
}
|
|
|
})
|
|
|
},
|