Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
M
mr-julyedu
Overview
Overview
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
baiguangyao
mr-julyedu
Commits
31f61665
Commit
31f61665
authored
Dec 17, 2019
by
zhanghaozhe
Browse files
Options
Browse Files
Download
Plain Diff
Merge branch '00'
parents
a14e0955
9de752cf
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
11 additions
and
17 deletions
+11
-17
src/components/activity/newyear-2019/landing/index.js
+11
-17
No files found.
src/components/activity/newyear-2019/landing/index.js
View file @
31f61665
...
...
@@ -44,6 +44,7 @@ class Landing extends Component {
fetchPageData
=
({
origin
=
this
.
state
.
origin
,
treasure_code
=
this
.
state
.
treasure_code
}
=
{})
=>
{
const
{
location
}
=
this
.
props
http
.
post
(
`
${
API
.
home
}
/sys/treasure/team`
,
{
treasure_code
,
origin
...
...
@@ -58,6 +59,16 @@ class Landing extends Component {
activityEnd
:
data
.
status
==
5
})
if
(
browser
.
isWeixin
)
{
wxShare
({
title
:
`@
${
data
.
member
[
0
].
user_name
}
邀您一起组队拿豪礼!`
,
desc
:
`加入我的队伍,机械键盘,纸质书籍等超多奖品等你拿!`
,
link
:
`
${
window
.
location
.
origin
}${
location
.
pathname
}
?treasure_code=
${
getParam
(
'treasure_code'
)}
&origin=2`
,
imgUrl
:
'https://julyedu-cdn.oss-cn-beijing.aliyuncs.com/newyear20/H5/wx-share-icon.png'
})
// history.replace(`${match.url}?treasure_code=${getParam('treasure_code')}&origin=2`)
}
let
searchParams
=
new
URLSearchParams
(
window
.
location
.
search
)
if
(
searchParams
.
get
(
'origin'
)
===
'1'
&&
!
browser
.
isWeixin
)
{
searchParams
.
set
(
'origin'
,
'2'
)
...
...
@@ -177,14 +188,6 @@ class Landing extends Component {
}
SendMessageToApp
(
"toShare"
,
data
)
}
if
(
browser
.
isWeixin
)
{
wxShare
({
title
:
`@
${
user
.
data
.
username
}
邀您一起组队拿豪礼!`
,
desc
:
`加入我的队伍,机械键盘,纸质书籍等超多奖品等你拿!`
,
link
:
`
${
window
.
location
.
origin
}${
location
.
pathname
}
?treasure_code=
${
treasure_code
}
&origin=2`
,
imgUrl
:
'https://julyedu-cdn.oss-cn-beijing.aliyuncs.com/newyear20/H5/wx-share-icon.png'
})
}
sessionStorage
.
setItem
(
'showShareTip'
,
'1'
)
history
.
replace
(
`
${
match
.
url
}
?treasure_code=
${
treasure_code
}
&origin=
${
1
}
`
)
this
.
createTeamSuccessPopup
&&
this
.
createTeamSuccessPopup
.
remove
()
&&
(
this
.
createTeamSuccessPopup
=
null
)
...
...
@@ -301,15 +304,6 @@ class Landing extends Component {
})
}
else
{
if
(
browser
.
isWeixin
&&
getParam
(
'origin'
)
==
1
)
{
wxShare
({
title
:
`@
${
user
.
data
.
username
}
邀您一起组队拿豪礼!`
,
desc
:
`加入我的队伍,机械键盘,纸质书籍等超多奖品等你拿!`
,
link
:
`
${
window
.
location
.
origin
}${
location
.
pathname
}
?treasure_code=
${
getParam
(
'treasure_code'
)}
&origin=2`
,
imgUrl
:
'https://julyedu-cdn.oss-cn-beijing.aliyuncs.com/newyear20/H5/wx-share-icon.png'
})
// history.replace(`${match.url}?treasure_code=${getParam('treasure_code')}&origin=2`)
}
Popup
({
title
:
<
div
>
还差
<
span
>
{
this
.
state
.
teamData
.
lack_member
}
<
/span>名队友即可获得宝箱 快分享给好友吧~</
div
>
,
className
:
`landing-share-tip
${
browser
.
isWeixin
?
'wechat'
:
''
}
`
,
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment