1.要求基础库2.11以上
onShow() {
this.onLoad()
this.ANNN()
},
ANNN() {
wx.showShareMenu({
withShareTicket: true,
menus: [‘shareAppMessage’, ‘shareTimeline’]
})
},
onShareAppMessage() {
let openid = this.data.openid
return {
title: '话费石化油卡充值',
imageUrl: "/images/1.png",
path: '/HF/home/home?TG=' + openid
}
},
onShareTimeline() {
let openid = this.data.openid
return {
title: '话费石化油卡充值',
imageUrl: "/images/1.png",
path: '/HF/home/home?TG=' + openid
}
},
3.效果