|
|
/* global wx */
|
|
|
const $ = require('yoho-jquery');
|
|
|
const lazyLoad = require('js/plugin/lazyload');
|
|
|
const Swiper = require('yoho-swiper');
|
...
|
...
|
@@ -213,19 +214,31 @@ function initWxShare(data) { |
|
|
}
|
|
|
};
|
|
|
|
|
|
if (window.wx) {
|
|
|
if (wx) {
|
|
|
setTimeout(function() {
|
|
|
window.wx.ready(function() {
|
|
|
window.wx.onMenuShareAppMessage(shareData);
|
|
|
wx.onMenuShareAppMessage(shareData);
|
|
|
|
|
|
window.wx.onMenuShareTimeline(shareData);
|
|
|
wx.onMenuShareTimeline(shareData);
|
|
|
|
|
|
window.wx.onMenuShareQQ(shareData);
|
|
|
wx.onMenuShareQQ(shareData);
|
|
|
|
|
|
window.wx.onMenuShareWeibo(shareData);
|
|
|
wx.onMenuShareWeibo(shareData);
|
|
|
});
|
|
|
}, 500);
|
|
|
|
|
|
if (isWechatMiniProgram) {
|
|
|
wx.miniProgram.postMessage({
|
|
|
data: {
|
|
|
title: data.title,
|
|
|
imgUrl: data.imgUrl,
|
|
|
link: data.link
|
|
|
}
|
|
|
});
|
|
|
}
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
// yo_sdk.wxShare(shareData);
|
|
|
}
|
...
|
...
|
|