我的H5对接微信JS-SDK中的扫码功能,发现在Android手机微信中无法调用扫码功能,在苹果手机微信中可以使用.
报如下错误:
errMsg:scanQRCode:permissi on denied
errMsg:config:invalid signature
部分代码如下:
jweixin.config({
debug: true,
appId: this.appId,
timestamp: this.timestamp,
nonceStr: this.nonceStr,
signature: this.signature,
jsApiList: [
‘checkJsApi’,
‘scanQRCode’
]
});
jweixin.checkJsApi({
jsApiList : [‘checkJsApi’,‘scanQRCode’],
success : function(res) {
}
});
jweixin.scanQRCode({
needResult: 1,
scanType: [“qrCode”,“barCode”],
success: function (res) {
_this.devicesn = res.resultStr;
}
});