微信小程序中调起付款码时,出现errMsg: "openOfflinePayView:fail"?
wx.openOfflinePayView 接口权限已向服务商申请开通,之前是提示 fail no permission的,权限开通后调起微信付款码时,出现 openOfflinePayView:fail,
签名结果与支付接口调试工具签名结果一致,目前还尚未找到具体原因
wx.request({
url: 'sign-url',
success: function(response) {
if(response.data.errcode==0) {
wx.openOfflinePayView({
appId: response.data.appId,
timeStamp: response.data.timeStamp,
nonceStr: response.data.nonceStr,
package: response.data.package, // package格式为:mch_id=商户号
signType: "MD5",
paySign: response.data.paySign,
success: function (a) {
console.log(a);
},
fail: function (a) {
console.log(a);
},
complete: function (a) {
console.log(a);
}
});
}
}
})
1 回复