我日, 一摸一样的 问题, 我也是微信ocr 识别失败,就是 鸿蒙5.0. 只有他有问题,我服了。
关于鸿蒙os5.0版本微信ocr识别相关问题?代码片段 wx.serviceMarket.invokeService({ service: 'wx79ac3de8be320b71', //固定的不要动 api: 'OcrAllInOne', //固定的不要动 data: { // 用 CDN 方法标记要上传并转换成 HTTP URL 的文件 img_url: new wx.serviceMarket.CDN({ type: 'filePath', filePath: this.urlsfz, }), data_type: 3, ocr_type: 1 // 1是身份证识别 }, success: function(res) { //识别结果 console.log(111, res) that.form.resiIdNo = res.data.idcard_res.id.text that.form.resiName = res.data.idcard_res.name.text uni.hideLoading(); }, failed: (error) => { uni.hideLoading(); console.log(222, error); } }) 用华为的mate60 鸿蒙5.0版本的手机扫码身份证,没反应 ,就是也不报错,也不继续往下走代码就卡在识别这里,不清楚是什么问题造成的
07-22