机型为魅蓝note3,微信版本6.5.13
wx.addCard({
cardList: [{
cardId: cardId,
cardExt: ‘{“code”: “”, “openid”:res.data.openid, “timestamp”:res.data.timestamp, “signature”:res.data.signature}’
}],
success: function (res) {
wx.request({
url: ‘https://XXX?code=’ + res.cardList[0].code,
data: ‘’,
header: {},
method: ‘get’,
dataType: ‘’,
success: function (res) {
wx.openCard({
cardList: [{
cardId: cardId,
code: res.data.code,
}],
success: function (res) { },
fail: function (res) { },
complete: function (res) {
console.log(res);
},
})
},
fail: function (res) { },
complete: function (res) {
console.log(res);
},
})
},
fail: function (res) { },
complete: function (res) {
console.log(res);
},
})
另外想问下,小程序的卡券到底干啥用,能不能就是像这俄格流程:微信创建的卡券可以显示在小程序里让用户领取,领取后在小程序里能看到领取的优惠券,在购物车结算时能选择已经领取的优惠券进行抵扣