小程序分享出来的card,第一次点击跳转的逻辑?
小程序分享出来的小程序卡片,带参数,用户第一次点击时会默认跳到小程序首页,不是分享时设置的页面路径,
请问这个问题是什么导致的?
4 回复
分享的代码:
onShareAppMessage: function () {
const { discountType, statusDesc, code } = this.data
let imageUrl = '/images/activity/share2.png'
let path = `/pages/red-packet/red-packet`
if (discountType === 2) {
path = '/pages/red-packet/red-packet'
imageUrl = '/images/activity/share-bg.png'
}
return {
title: statusDesc,
path: `${path}?code=${code}&discountType=${discountType}`,
imageUrl
}
}