| | |
| | | getResultInfo(data){ |
| | | if(!data.includes("part_no")){ |
| | | this.$message({ |
| | | message: '未识别出二位码零件信息!', |
| | | message: '未识别出二维码零件信息!', |
| | | type: 'warning' |
| | | }); |
| | | } |
| | | let obj=JSON.parse(data) |
| | | let info={"code":obj["part_no"]} |
| | | console.log("值",info); |
| | | if(info.code!=undefined&&info.code!=''){ |
| | | this.paramObj = info |
| | | this.showPart = true |
| | | }else{ |
| | | this.$message({ |
| | | message: '未识别出二位码零件信息!', |
| | | message: '未识别出二维码零件信息!', |
| | | type: 'warning' |
| | | }); |
| | | } |
| | |
| | | }, |
| | | // 打开相机 |
| | | Turnonthecamera() { |
| | | this.qrcode = true |
| | | this.$refs.codeCompont.openCamera() |
| | | }, |
| | | this.qrcode = true |
| | | this.$refs.codeCompont.openCamera() |
| | | }, |
| | | // 确认回调 |
| | | selectPart(param, nodePart, index) { |
| | | if (typeof param !== 'undefined') { |