Toggle navigation
Toggle navigation
This project
Loading...
Sign in
fe
/
yohobuywap-node
·
Commits
Go to a project
GitLab
Go to group
Project
Activity
Files
Commits
Pipelines
0
Builds
0
Graphs
Milestones
Issues
0
Merge Requests
0
Members
Labels
Wiki
Forks
Network
Create a new issue
Download as
Email Patches
Plain Diff
Browse Files
Authored by
邱骏
6 years ago
Commit
2749977f66bb88109389c8062e8641cdac1c2bef
1 parent
0b72d9da
调整分享页面
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
29 additions
and
4 deletions
doraemon/views/partial/analysis.hbs
public/js/activity/feature.page.js
doraemon/views/partial/analysis.hbs
View file @
2749977
...
...
@@ -12,7 +12,7 @@
a.async = 1;
a.src = j;
m.parentNode.insertBefore(a, m); // '//cdn.yoho.cn/yas-jssdk/2.4.20/yas.js'
}(window, document, 'script', (document.location.protocol === 'https:' ? 'https:' : 'http:') + '//
ad.yoho.cn/html5/sdk/yas-sdk/015
/2.4.21/yas.js', '_yas'));
}(window, document, 'script', (document.location.protocol === 'https:' ? 'https:' : 'http:') + '//
cdn.yoho.cn/yas-jssdk
/2.4.21/yas.js', '_yas'));
var _hmt = _hmt || [];
...
...
public/js/activity/feature.page.js
View file @
2749977
/* global wx */
const
$
=
require
(
'yoho-jquery'
);
const
lazyLoad
=
require
(
'js/plugin/lazyload'
);
const
Swiper
=
require
(
'yoho-swiper'
);
...
...
@@ -147,7 +148,6 @@ function getCoupon() { // 分享成功后领券
}
function
checkShare
(
shareData
)
{
console
.
log
(
shareData
);
if
(
isApp
)
{
let
newShare
=
false
;
let
app_vercode
=
cookie
.
get
(
'app_vercode'
);
...
...
@@ -219,7 +219,31 @@ function initWxShare(data) {
}
};
yo_sdk
.
wxShare
(
shareData
);
if
(
wx
)
{
setTimeout
(
function
()
{
window
.
wx
.
ready
(
function
()
{
wx
.
onMenuShareAppMessage
(
shareData
);
wx
.
onMenuShareTimeline
(
shareData
);
wx
.
onMenuShareQQ
(
shareData
);
wx
.
onMenuShareWeibo
(
shareData
);
});
},
500
);
if
(
isWechatMiniProgram
)
{
wx
.
miniProgram
.
postMessage
({
data
:
{
title
:
data
.
title
,
imgUrl
:
data
.
imgUrl
,
link
:
data
.
link
}
});
}
}
// yo_sdk.wxShare(shareData);
}
function
initWebShareButtons
(
env
=
''
)
{
// 初始化分享按钮事件
...
...
@@ -268,7 +292,8 @@ function initWebShareButtons(env = '') { // 初始化分享按钮事件
Object
.
assign
(
webShareData
,
{
hideType
:
[
'4'
,
'5'
,
'6'
,
'7'
,
'8'
,
'9'
],
isCareCallBack
:
'1'
,
wxShareMode
:
parseInt
(
webShareButton
.
data
(
'slanding'
),
10
)
?
'miniprogram'
:
'h5'
wxShareMode
:
parseInt
(
webShareButton
.
data
(
'slanding'
),
10
)
?
'miniprogram'
:
'h5'
,
miniProgramUrl
:
'pages/webview/webview?url='
+
webShareData
.
link
// 安卓分享小程序会用到
});
}
...
...
Please
register
or
login
to post a comment