Commit b9e94bb3 authored by 黄媛媛's avatar 黄媛媛

1

parent 375fa98c
......@@ -367,7 +367,22 @@ export default {
this.secondary = this.$uiConfig.secondary;
this.setting = uni.getStorageSync("basedata").mall.setting;
wx.showShareMenu({
withShareTicket:true,
menus:['shareAppMessage','shareTimeline']
})
},
onShareTimeline(){
let uid=uni.getStorageSync('mall_UserInfo') ?uni.getStorageSync('mall_UserInfo').UserId:0;
let title = this.g.app_share_title != null && this.g.app_share_title != ""? this.g.app_share_title : this.g.name;
let imageUrl = this.g.app_share_pic != null && this.g.app_share_pic != ""? this.g.app_share_pic : this.g.pic_url[0].pic_url;
let id = this.id
return{
title: title,
query: "id=" + this.id + "&user_id=" + uid,
imageUrl: imageUrl
}
},
onShareAppMessage(res) {
let u = uni.getStorageSync("mall_UserInfo");
let uid = u.UserId ? u.UserId : 0;
......
......@@ -137,11 +137,6 @@ export default {
quicknav
},
onLoad(options) {
// let options= {//测试
// scene:'share',
// user_id:19992,
// params:{"id":106118,"path":"/pages/goods/goods","user_id":19992}
// }
console.log(options,'option');
let c = this.$uiConfig.is_bang ? 78 : 50;
this.contentHeight = this.$utils.calcContentHeight(c);
......@@ -158,7 +153,10 @@ export default {
this.getjump(options.scene)
}
wx.showShareMenu({
withShareTicket:true,
menus:['shareAppMessage','shareTimeline']
})
this.init();
......@@ -172,6 +170,15 @@ export default {
console.log(uni.getStorageSync("basedata"))
uni.showNavigationBarLoading();
},
onShareTimeline(){
let uid=uni.getStorageSync('mall_UserInfo') ?uni.getStorageSync('mall_UserInfo').UserId:0;
console.log(uid)
return{
title: '',
query: "user_id=" + uid,
imageUrl: ''
}
},
onShareAppMessage(res) {
let uid=uni.getStorageSync('mall_UserInfo') ?uni.getStorageSync('mall_UserInfo').UserId:0
return {
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment