Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
2
20250711_TBGuardingLife
Project
Project
Details
Activity
Releases
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
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Commits
Issue Boards
Open sidebar
SparkProjects
20250711_TBGuardingLife
Commits
2df13986
Commit
2df13986
authored
Jul 17, 2025
by
俞嘉婷
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
feat: 神策埋点
parent
1376a784
Changes
19
Hide whitespace changes
Inline
Side-by-side
Showing
19 changed files
with
88 additions
and
334 deletions
+88
-334
turn.js
mock/project/turn.js
+2
-2
index.html
public/index.html
+2
-2
FundsPanel.jsx
src/components/FundsPanel/FundsPanel.jsx
+10
-1
drawchancepop.jsx
src/components/drawchancepop/drawchancepop.jsx
+2
-2
drawfailpop.jsx
src/components/drawfailpop/drawfailpop.jsx
+3
-2
drawsucpop.jsx
src/components/drawsucpop/drawsucpop.jsx
+3
-4
rulepop.jsx
src/components/rulepop/rulepop.jsx
+2
-2
taskpop.jsx
src/components/taskpop/taskpop.jsx
+7
-6
LifeSettingPage.jsx
src/pages/LifeSettingPage/LifeSettingPage.jsx
+8
-5
answerpage.jsx
src/pages/answerpage/answerpage.jsx
+3
-0
drawpage.jsx
src/pages/drawpage/drawpage.jsx
+6
-9
drawpage.less
src/pages/drawpage/drawpage.less
+0
-26
homepage.jsx
src/pages/homepage/homepage.jsx
+8
-12
homepage.less
src/pages/homepage/homepage.less
+0
-26
prizepage.jsx
src/pages/prizepage/prizepage.jsx
+2
-2
resultpage.jsx
src/pages/resultpage/resultpage.jsx
+3
-4
index.js
src/store/index.js
+3
-3
constants.js
src/utils/constants.js
+0
-221
sensorMd.js
src/utils/sensorMd.js
+24
-5
No files found.
mock/project/turn.js
View file @
2df13986
...
@@ -63,7 +63,7 @@ module.exports = {
...
@@ -63,7 +63,7 @@ module.exports = {
prizeType
:
0
,
prizeType
:
0
,
},
},
],
],
leftDrawTimes
:
0
,
leftDrawTimes
:
1
0
,
},
},
message
:
null
,
message
:
null
,
success
:
true
,
success
:
true
,
...
@@ -79,7 +79,7 @@ module.exports = {
...
@@ -79,7 +79,7 @@ module.exports = {
optionId
:
"ccccdddd"
,
optionId
:
"ccccdddd"
,
optionName
:
"华为手环"
,
optionName
:
"华为手环"
,
optionImg
:
"https://www.baidu.com/hw1.png"
,
optionImg
:
"https://www.baidu.com/hw1.png"
,
prizeId
:
"
sss_3
"
,
prizeId
:
"
thanks
"
,
prizeType
:
2
,
prizeType
:
2
,
position
:
1
,
position
:
1
,
userRecordId
:
666
,
userRecordId
:
666
,
...
...
public/index.html
View file @
2df13986
...
@@ -7,7 +7,7 @@
...
@@ -7,7 +7,7 @@
<meta
name=
"theme-color"
content=
"#000000"
>
<meta
name=
"theme-color"
content=
"#000000"
>
<link
rel=
"dns-prefetch"
href=
"//yun.duiba.com.cn"
/>
<link
rel=
"dns-prefetch"
href=
"//yun.duiba.com.cn"
/>
<link
rel=
"preconnect"
href=
"//embedlog.duiba.com.cn"
>
<link
rel=
"preconnect"
href=
"//embedlog.duiba.com.cn"
>
<title>
粽意测试局
</title>
<title>
守护人生实验
</title>
<script
type=
"text/javascript"
>
<script
type=
"text/javascript"
>
if
(
localStorage
&&
localStorage
.
isWebp
)
{
if
(
localStorage
&&
localStorage
.
isWebp
)
{
document
document
...
@@ -34,7 +34,7 @@
...
@@ -34,7 +34,7 @@
CFG
.
appID
=
'${APPID}'
;
CFG
.
appID
=
'${APPID}'
;
CFG
.
activityName
=
"官微-25
端午节
活动"
;
CFG
.
activityName
=
"官微-25
年守护人生
活动"
;
CFG
.
channel
=
getUrlParam
(
"channel"
)
||
sessionStorage
.
getItem
(
"channel"
)
CFG
.
channel
=
getUrlParam
(
"channel"
)
||
sessionStorage
.
getItem
(
"channel"
)
CFG
.
empno
=
getUrlParam
(
'empno'
)
||
sessionStorage
.
getItem
(
"empno"
)
CFG
.
empno
=
getUrlParam
(
'empno'
)
||
sessionStorage
.
getItem
(
"empno"
)
CFG
.
empname
=
getUrlParam
(
'empname'
)
||
sessionStorage
.
getItem
(
"empname"
)
CFG
.
empname
=
getUrlParam
(
'empname'
)
||
sessionStorage
.
getItem
(
"empname"
)
...
...
src/components/FundsPanel/FundsPanel.jsx
View file @
2df13986
...
@@ -7,14 +7,23 @@ import {Button} from "@src/components/Button";
...
@@ -7,14 +7,23 @@ import {Button} from "@src/components/Button";
import
store
from
"@src/store"
;
import
store
from
"@src/store"
;
import
{
PAGE_MAP
}
from
"@src/utils/constants"
;
import
{
PAGE_MAP
}
from
"@src/utils/constants"
;
import
modalStore
from
"@src/store/modal"
;
import
modalStore
from
"@src/store/modal"
;
import
{
sensorMdClick
,
sensorMdExpouse
}
from
"@src/utils/sensorMd"
;
@
observer
@
observer
class
FundsPanel
extends
React
.
Component
{
class
FundsPanel
extends
React
.
Component
{
componentDidMount
()
{
componentDidMount
()
{
sensorMdExpouse
(
"PopupExpouse"
,
{
pageName
:
"守护人生活动-人生资金弹窗"
});
}
}
clickNext
=
()
=>
{
clickNext
=
()
=>
{
sensorMdClick
(
"PopupClick"
,
{
pageName
:
"守护人生活动-人生资金弹窗"
,
buttonName
:
"去配置"
});
modalStore
.
closePop
();
store
.
changePage
(
PAGE_MAP
.
QUES_PAGE
,
{
funds
:
this
.
props
.
popData
.
funds
});
}
clickClose
=
()
=>
{
sensorMdClick
(
"PopupClick"
,
{
pageName
:
"守护人生活动-人生资金弹窗"
,
buttonName
:
"关闭"
});
modalStore
.
closePop
();
modalStore
.
closePop
();
store
.
changePage
(
PAGE_MAP
.
QUES_PAGE
,
{
funds
:
this
.
props
.
popData
.
funds
});
store
.
changePage
(
PAGE_MAP
.
QUES_PAGE
,
{
funds
:
this
.
props
.
popData
.
funds
});
}
}
...
@@ -28,7 +37,7 @@ class FundsPanel extends React.Component {
...
@@ -28,7 +37,7 @@ class FundsPanel extends React.Component {
<
div
className=
"bg"
/>
<
div
className=
"bg"
/>
<
div
className=
"funds"
>
{
funds
}
万元
</
div
>
<
div
className=
"funds"
>
{
funds
}
万元
</
div
>
<
Button
className=
"next"
onClick=
{
this
.
clickNext
}
/>
<
Button
className=
"next"
onClick=
{
this
.
clickNext
}
/>
<
Button
className=
"close"
onClick=
{
this
.
click
Next
}
/>
<
Button
className=
"close"
onClick=
{
this
.
click
Close
}
/>
</
div
>;
</
div
>;
}
}
}
}
...
...
src/components/drawchancepop/drawchancepop.jsx
View file @
2df13986
...
@@ -14,11 +14,11 @@ class Drawchancepop extends React.Component {
...
@@ -14,11 +14,11 @@ class Drawchancepop extends React.Component {
}
}
componentDidMount
()
{
componentDidMount
()
{
sensorMdExpouse
(
"PopupExpouse"
,
{
pageName
:
"提示获取抽奖机会弹窗"
});
//
sensorMdExpouse("PopupExpouse", { pageName: "提示获取抽奖机会弹窗" });
}
}
handleClick
=
()
=>
{
handleClick
=
()
=>
{
sensorMdClick
(
"PopupClick"
,
{
pageName
:
"提示获取抽奖机会弹窗点击"
,
buttonName
:
"去做任务"
});
//
sensorMdClick("PopupClick", { pageName: "提示获取抽奖机会弹窗点击", buttonName: "去做任务" });
modalStore
.
closePop
(
"Drawchancepop"
);
modalStore
.
closePop
(
"Drawchancepop"
);
modalStore
.
pushPop
(
"Taskpop"
,
{
refresh
:
this
.
props
.
popData
.
refresh
})
modalStore
.
pushPop
(
"Taskpop"
,
{
refresh
:
this
.
props
.
popData
.
refresh
})
}
}
...
...
src/components/drawfailpop/drawfailpop.jsx
View file @
2df13986
...
@@ -15,11 +15,11 @@ class Drawfailpop extends React.Component {
...
@@ -15,11 +15,11 @@ class Drawfailpop extends React.Component {
}
}
componentDidMount
()
{
componentDidMount
()
{
sensorMdExpouse
(
"PopupExpouse"
,
{
pageName
:
"未中奖弹窗"
});
sensorMdExpouse
(
"PopupExpouse"
,
{
pageName
:
"
守护人生活动-
未中奖弹窗"
});
}
}
knowHandle
=
_throttle
(()
=>
{
knowHandle
=
_throttle
(()
=>
{
sensorMdClick
(
"PopupClick"
,
{
pageName
:
"
未中奖弹窗点击"
,
buttonName
:
"我知道啦
"
});
sensorMdClick
(
"PopupClick"
,
{
pageName
:
"
守护人生活动-未中奖弹窗"
,
buttonName
:
"我知道了
"
});
modalStore
.
closePop
();
modalStore
.
closePop
();
});
});
...
@@ -32,6 +32,7 @@ class Drawfailpop extends React.Component {
...
@@ -32,6 +32,7 @@ class Drawfailpop extends React.Component {
<
span
<
span
className=
"close"
className=
"close"
onClick=
{
()
=>
{
onClick=
{
()
=>
{
sensorMdClick
(
"PopupClick"
,
{
pageName
:
"守护人生活动-未中奖弹窗"
,
buttonName
:
"关闭"
});
modalStore
.
closePop
();
modalStore
.
closePop
();
}
}
></
span
>
}
}
></
span
>
</
div
>
</
div
>
...
...
src/components/drawsucpop/drawsucpop.jsx
View file @
2df13986
...
@@ -17,18 +17,17 @@ class Drawsucpop extends React.Component {
...
@@ -17,18 +17,17 @@ class Drawsucpop extends React.Component {
}
}
componentDidMount
()
{
componentDidMount
()
{
sensorMdExpouse
(
"PopupExpouse"
,
{
pageName
:
"
中奖弹窗"
,
prize
:
this
.
props
?.
popData
?.
prizeName
});
sensorMdExpouse
(
"PopupExpouse"
,
{
pageName
:
"
守护人生活动-中奖弹窗"
});
}
}
/** 进入【奖品】页 */
/** 进入【奖品】页 */
jumpPrize
=
_throttle
(()
=>
{
jumpPrize
=
_throttle
(()
=>
{
sensorMdClick
(
"PopupClick"
,
{
sensorMdClick
(
"PopupClick"
,
{
pageName
:
"
中奖弹窗点击
"
,
pageName
:
"
守护人生活动-中奖弹窗
"
,
buttonName
:
"开心收下"
,
buttonName
:
"开心收下"
,
prize
:
this
.
props
?.
popData
?.
prizeName
,
});
});
modalStore
.
closePop
();
modalStore
.
closePop
();
location
.
href
=
CFG
.
prize
;
//
location.href = CFG.prize;
});
});
render
()
{
render
()
{
const
{
optionName
,
optionImg
}
=
this
.
props
.
popData
?.
prize
||
{};
const
{
optionName
,
optionImg
}
=
this
.
props
.
popData
?.
prize
||
{};
...
...
src/components/rulepop/rulepop.jsx
View file @
2df13986
...
@@ -15,12 +15,12 @@ class Rulepop extends React.Component {
...
@@ -15,12 +15,12 @@ class Rulepop extends React.Component {
super
(
props
);
super
(
props
);
}
}
async
componentDidMount
()
{
async
componentDidMount
()
{
sensorMdExpouse
(
"PopupExpouse"
,
{
pageName
:
"
活动
规则弹窗"
});
sensorMdExpouse
(
"PopupExpouse"
,
{
pageName
:
"
守护人生活动-
规则弹窗"
});
await
store
.
initRule
();
await
store
.
initRule
();
}
}
closeHandle
=
_throttle
(()
=>
{
closeHandle
=
_throttle
(()
=>
{
sensorMdClick
(
"PopupClick"
,
{
pageName
:
"
活动规则弹窗点击
"
,
buttonName
:
"关闭"
});
sensorMdClick
(
"PopupClick"
,
{
pageName
:
"
守护人生活动-规则弹窗
"
,
buttonName
:
"关闭"
});
modalStore
.
closePop
();
modalStore
.
closePop
();
});
});
...
...
src/components/taskpop/taskpop.jsx
View file @
2df13986
...
@@ -27,7 +27,7 @@ class Taskpop extends React.Component {
...
@@ -27,7 +27,7 @@ class Taskpop extends React.Component {
};
};
}
}
async
componentDidMount
()
{
async
componentDidMount
()
{
sensorMdExpouse
(
"PopupExpouse"
,
{
pageName
:
"任务
弹窗
"
});
sensorMdExpouse
(
"PopupExpouse"
,
{
pageName
:
"任务
页
"
});
this
.
getTaskList
();
this
.
getTaskList
();
}
}
...
@@ -58,6 +58,7 @@ class Taskpop extends React.Component {
...
@@ -58,6 +58,7 @@ class Taskpop extends React.Component {
// 按钮点击事件
// 按钮点击事件
completeHandle
=
_throttle
(
async
(
item
)
=>
{
completeHandle
=
_throttle
(
async
(
item
)
=>
{
handleLogClick
(
23
);
handleLogClick
(
23
);
sensorMdClick
(
"PopupClick"
,
{
pageName
:
"任务页"
,
buttonName
:
"去完成"
});
const
{
userId
}
=
store
.
homeInfo
||
{};
const
{
userId
}
=
store
.
homeInfo
||
{};
const
{
code
,
jumpUrl
}
=
item
||
{};
const
{
code
,
jumpUrl
}
=
item
||
{};
const
systemTime
=
Date
.
now
();
const
systemTime
=
Date
.
now
();
...
@@ -68,12 +69,12 @@ class Taskpop extends React.Component {
...
@@ -68,12 +69,12 @@ class Taskpop extends React.Component {
timestamp
:
systemTime
,
timestamp
:
systemTime
,
};
};
if
(
code
.
indexOf
(
TASK_CODE
.
THIRD_RETAIN
)
>
-
1
)
{
if
(
code
.
indexOf
(
TASK_CODE
.
THIRD_RETAIN
)
>
-
1
)
{
sensorMdClick
(
"PopupClick"
,
{
pageName
:
"任务弹窗点击
"
,
buttonName
:
"留资咨询"
});
// sensorMdClick("PopupClick", { pageName: "任务页
", buttonName: "留资咨询" });
setTimeout
(()
=>
{
setTimeout
(()
=>
{
windowJumpUrl
(
jumpUrl
);
windowJumpUrl
(
jumpUrl
);
},
300
);
},
300
);
}
else
if
(
code
.
indexOf
(
TASK_CODE
.
BROWSE_PRODUCT
)
>
-
1
)
{
}
else
if
(
code
.
indexOf
(
TASK_CODE
.
BROWSE_PRODUCT
)
>
-
1
)
{
sensorMdClick
(
"PopupClick"
,
{
pageName
:
"任务弹窗点击
"
,
buttonName
:
"浏览产品"
});
// sensorMdClick("PopupClick", { pageName: "任务页
", buttonName: "浏览产品" });
modalStore
.
pushPop
(
"LongImgPop"
,
{
modalStore
.
pushPop
(
"LongImgPop"
,
{
imgUrl
:
jumpUrl
,
imgUrl
:
jumpUrl
,
taskSucCb
:
async
()
=>
{
taskSucCb
:
async
()
=>
{
...
@@ -81,7 +82,7 @@ class Taskpop extends React.Component {
...
@@ -81,7 +82,7 @@ class Taskpop extends React.Component {
},
},
});
});
}
else
if
(
code
.
indexOf
(
TASK_CODE
.
SIGN
)
>
-
1
)
{
}
else
if
(
code
.
indexOf
(
TASK_CODE
.
SIGN
)
>
-
1
)
{
sensorMdClick
(
"PopupClick"
,
{
pageName
:
"任务弹窗点击
"
,
buttonName
:
"每日签到"
});
// sensorMdClick("PopupClick", { pageName: "任务页
", buttonName: "每日签到" });
}
else
if
(
code
.
indexOf
(
TASK_CODE
.
BROWSE_MINI
)
>
-
1
)
{
}
else
if
(
code
.
indexOf
(
TASK_CODE
.
BROWSE_MINI
)
>
-
1
)
{
await
API
.
doCompleted
(
params
);
await
API
.
doCompleted
(
params
);
watchPageVisibility
(
this
.
pageVChange
);
watchPageVisibility
(
this
.
pageVChange
);
...
@@ -93,7 +94,7 @@ class Taskpop extends React.Component {
...
@@ -93,7 +94,7 @@ class Taskpop extends React.Component {
miniGoUrl
(
jumpUrl
);
miniGoUrl
(
jumpUrl
);
}
}
}
else
if
(
code
.
indexOf
(
TASK_CODE
.
BROWSE_VIDEO
)
>
-
1
)
{
}
else
if
(
code
.
indexOf
(
TASK_CODE
.
BROWSE_VIDEO
)
>
-
1
)
{
sensorMdClick
(
"PopupClick"
,
{
pageName
:
"任务弹窗点击
"
,
buttonName
:
"浏览视频"
});
// sensorMdClick("PopupClick", { pageName: "任务页
", buttonName: "浏览视频" });
modalStore
.
pushPop
(
"Videopop"
,
{
modalStore
.
pushPop
(
"Videopop"
,
{
url
:
jumpUrl
,
url
:
jumpUrl
,
taskSucCb
:
async
()
=>
{
taskSucCb
:
async
()
=>
{
...
@@ -106,6 +107,7 @@ class Taskpop extends React.Component {
...
@@ -106,6 +107,7 @@ class Taskpop extends React.Component {
/** 任务领奖 */
/** 任务领奖 */
receiveHandle
=
_asyncThrottle
(
async
(
task
)
=>
{
receiveHandle
=
_asyncThrottle
(
async
(
task
)
=>
{
handleLogClick
(
23
);
handleLogClick
(
23
);
sensorMdClick
(
"PopupClick"
,
{
pageName
:
"任务页"
,
buttonName
:
"去领取"
});
const
{
success
,
data
}
=
await
API
.
sendPrize
({
const
{
success
,
data
}
=
await
API
.
sendPrize
({
// taskId: task.id,
// taskId: task.id,
taskCode
:
task
.
code
,
taskCode
:
task
.
code
,
...
@@ -119,7 +121,6 @@ class Taskpop extends React.Component {
...
@@ -119,7 +121,6 @@ class Taskpop extends React.Component {
/* 关闭弹窗*/
/* 关闭弹窗*/
closeHandle
=
()
=>
{
closeHandle
=
()
=>
{
sensorMdClick
(
"PopupClick"
,
{
pageName
:
"任务弹窗点击"
,
buttonName
:
"关闭"
});
this
.
props
.
popData
?.
refresh
&&
this
.
props
.
popData
?.
refresh
();
this
.
props
.
popData
?.
refresh
&&
this
.
props
.
popData
?.
refresh
();
modalStore
.
closePop
();
modalStore
.
closePop
();
};
};
...
...
src/pages/LifeSettingPage/LifeSettingPage.jsx
View file @
2df13986
...
@@ -9,6 +9,7 @@ import store from "@src/store";
...
@@ -9,6 +9,7 @@ import store from "@src/store";
import
{
PAGE_MAP
}
from
"@src/utils/constants"
;
import
{
PAGE_MAP
}
from
"@src/utils/constants"
;
import
{
Toast
}
from
"@spark/ui"
;
import
{
Toast
}
from
"@spark/ui"
;
import
modalStore
from
"@src/store/modal"
;
import
modalStore
from
"@src/store/modal"
;
import
{
sensorMdClick
,
sensorMdExpouse
}
from
"@src/utils/sensorMd"
;
@
observer
@
observer
class
LifeSettingPage
extends
React
.
Component
{
class
LifeSettingPage
extends
React
.
Component
{
...
@@ -22,6 +23,7 @@ class LifeSettingPage extends React.Component {
...
@@ -22,6 +23,7 @@ class LifeSettingPage extends React.Component {
settingParams
=
[];
settingParams
=
[];
componentDidMount
()
{
componentDidMount
()
{
sensorMdExpouse
(
"activityPage"
,
{
pageName
:
"人生参数设定页"
});
}
}
clickItem
(
index
)
{
clickItem
(
index
)
{
...
@@ -32,18 +34,19 @@ class LifeSettingPage extends React.Component {
...
@@ -32,18 +34,19 @@ class LifeSettingPage extends React.Component {
clickNext
=
()
=>
{
clickNext
=
()
=>
{
const
{
chooseIndex
,
quesIndex
}
=
this
.
state
;
const
{
chooseIndex
,
quesIndex
}
=
this
.
state
;
if
(
chooseIndex
===
null
||
chooseIndex
===
undefined
)
{
if
(
chooseIndex
===
null
||
chooseIndex
===
undefined
)
{
return
Toast
(
"请完成参数选择"
);
return
Toast
(
"请完成参数选择"
);
}
}
const
{
radio
}
=
SettingCfg
[
quesIndex
].
answer
[
chooseIndex
];
const
{
radio
}
=
SettingCfg
[
quesIndex
].
answer
[
chooseIndex
];
this
.
funds
*=
radio
;
this
.
funds
*=
radio
;
this
.
settingParams
.
push
(
chooseIndex
);
this
.
settingParams
.
push
(
chooseIndex
);
if
(
quesIndex
==
2
)
{
if
(
quesIndex
==
2
)
{
sensorMdClick
(
"activityClick"
,
{
pageName
:
"人生参数设定页"
,
buttonName
:
"开始测试"
});
modalStore
.
pushPop
(
"FundsPanel"
,
{
modalStore
.
pushPop
(
"FundsPanel"
,
{
funds
:
this
.
funds
,
funds
:
this
.
funds
,
settingParams
:
this
.
settingParams
.
map
((
item
)
=>
item
+
1
),
settingParams
:
this
.
settingParams
.
map
((
item
)
=>
item
+
1
),
...
...
src/pages/answerpage/answerpage.jsx
View file @
2df13986
...
@@ -7,6 +7,7 @@ import {QuestionCfg} from "@src/pages/answerpage/QuestionCfg";
...
@@ -7,6 +7,7 @@ import {QuestionCfg} from "@src/pages/answerpage/QuestionCfg";
import
classNames
from
"classnames"
;
import
classNames
from
"classnames"
;
import
modalStore
from
"@src/store/modal"
;
import
modalStore
from
"@src/store/modal"
;
import
store
from
"@src/store"
;
import
store
from
"@src/store"
;
import
{
sensorMdClick
,
sensorMdExpouse
}
from
"@src/utils/sensorMd"
;
@
observer
@
observer
class
Answerpage
extends
React
.
Component
{
class
Answerpage
extends
React
.
Component
{
...
@@ -23,6 +24,7 @@ class Answerpage extends React.Component {
...
@@ -23,6 +24,7 @@ class Answerpage extends React.Component {
this
.
setState
({
this
.
setState
({
funds
:
this
.
props
.
funds
,
funds
:
this
.
props
.
funds
,
})
})
sensorMdExpouse
(
"activityPage"
,
{
pageName
:
"测试选择页"
});
}
}
clickItem
(
index
)
{
clickItem
(
index
)
{
...
@@ -32,6 +34,7 @@ class Answerpage extends React.Component {
...
@@ -32,6 +34,7 @@ class Answerpage extends React.Component {
}
}
clickNext
=
()
=>
{
clickNext
=
()
=>
{
sensorMdClick
(
"activityClick"
,
{
pageName
:
"测试选择页"
,
buttonName
:
"确认"
});
const
{
quesIndex
,
chooseIndex
,
funds
}
=
this
.
state
;
const
{
quesIndex
,
chooseIndex
,
funds
}
=
this
.
state
;
if
(
chooseIndex
==
null
)
return
;
if
(
chooseIndex
==
null
)
return
;
...
...
src/pages/drawpage/drawpage.jsx
View file @
2df13986
...
@@ -51,7 +51,7 @@ class Drawpage extends React.Component {
...
@@ -51,7 +51,7 @@ class Drawpage extends React.Component {
// 开始抽奖
// 开始抽奖
lotteryHandle
=
_asyncThrottle
(
async
()
=>
{
lotteryHandle
=
_asyncThrottle
(
async
()
=>
{
const
{
optionInfoList
,
leftDrawTimes
}
=
this
.
state
.
drawInfo
;
const
{
optionInfoList
,
leftDrawTimes
}
=
this
.
state
.
drawInfo
;
sensorMdClick
(
"activityClick"
,
{
pageName
:
"抽奖页
点击"
,
buttonName
:
"开始
抽奖"
});
sensorMdClick
(
"activityClick"
,
{
pageName
:
"抽奖页
"
,
buttonName
:
"立即
抽奖"
});
// 无抽奖次数
// 无抽奖次数
if
(
!
leftDrawTimes
)
{
if
(
!
leftDrawTimes
)
{
// return modalStore.pushPop("Drawchancepop", {
// return modalStore.pushPop("Drawchancepop", {
...
@@ -83,8 +83,9 @@ class Drawpage extends React.Component {
...
@@ -83,8 +83,9 @@ class Drawpage extends React.Component {
// 转盘停止处理
// 转盘停止处理
stopOkHandle
=
()
=>
{
stopOkHandle
=
()
=>
{
this
.
btnStarting
=
false
;
this
.
btnStarting
=
false
;
console
.
info
(
"this.drawResultInfo"
,
this
.
drawResultInfo
);
if
(
this
.
drawResultInfo
?.
prizeId
==
"thanks"
)
{
if
(
this
.
drawResultInfo
?.
prize
?.
prize
Id
==
"thanks"
)
{
modalStore
.
pushPop
(
"Drawfailpop"
);
modalStore
.
pushPop
(
"Drawfailpop"
);
}
else
{
}
else
{
modalStore
.
pushPop
(
"Drawsucpop"
,
{
...
this
.
drawResultInfo
});
modalStore
.
pushPop
(
"Drawsucpop"
,
{
...
this
.
drawResultInfo
});
...
@@ -102,7 +103,7 @@ class Drawpage extends React.Component {
...
@@ -102,7 +103,7 @@ class Drawpage extends React.Component {
prizeHandle
=
_throttle
(
async
()
=>
{
prizeHandle
=
_throttle
(
async
()
=>
{
if
(
this
.
btnStarting
)
return
false
;
if
(
this
.
btnStarting
)
return
false
;
if
(
!
store
.
checkActStatus
(
true
))
return
;
if
(
!
store
.
checkActStatus
(
true
))
return
;
sensorMdClick
(
"activityClick"
,
{
pageName
:
"抽奖页
点击
"
,
buttonName
:
"奖品"
});
sensorMdClick
(
"activityClick"
,
{
pageName
:
"抽奖页"
,
buttonName
:
"奖品"
});
location
.
href
=
CFG
.
prize
;
location
.
href
=
CFG
.
prize
;
});
});
...
@@ -110,14 +111,14 @@ class Drawpage extends React.Component {
...
@@ -110,14 +111,14 @@ class Drawpage extends React.Component {
ruleHandle
=
_throttle
(
async
()
=>
{
ruleHandle
=
_throttle
(
async
()
=>
{
if
(
this
.
btnStarting
)
return
false
;
if
(
this
.
btnStarting
)
return
false
;
if
(
!
store
.
checkActStatus
(
true
))
return
;
if
(
!
store
.
checkActStatus
(
true
))
return
;
sensorMdClick
(
"activityClick"
,
{
pageName
:
"抽奖页
点击
"
,
buttonName
:
"规则"
});
sensorMdClick
(
"activityClick"
,
{
pageName
:
"抽奖页"
,
buttonName
:
"规则"
});
modalStore
.
pushPop
(
"Rulepop"
);
modalStore
.
pushPop
(
"Rulepop"
);
});
});
/** 任务 */
/** 任务 */
taskHandle
=
_throttle
(()
=>
{
taskHandle
=
_throttle
(()
=>
{
if
(
this
.
btnStarting
)
return
false
;
if
(
this
.
btnStarting
)
return
false
;
if
(
!
store
.
checkActStatus
())
return
;
if
(
!
store
.
checkActStatus
())
return
;
sensorMdClick
(
"activityClick"
,
{
pageName
:
"抽奖页
点击
"
,
buttonName
:
"做任务"
});
sensorMdClick
(
"activityClick"
,
{
pageName
:
"抽奖页"
,
buttonName
:
"做任务"
});
modalStore
.
pushPop
(
"Taskpop"
,
{
modalStore
.
pushPop
(
"Taskpop"
,
{
refresh
:
()
=>
this
.
getDrawInfo
(),
refresh
:
()
=>
this
.
getDrawInfo
(),
});
});
...
@@ -129,10 +130,6 @@ class Drawpage extends React.Component {
...
@@ -129,10 +130,6 @@ class Drawpage extends React.Component {
<
span
className=
"beiJing"
></
span
>
<
span
className=
"beiJing"
></
span
>
<
div
className=
"rule_prize"
></
div
>
<
div
className=
"rule_prize"
></
div
>
<
span
className=
"title"
></
span
>
<
span
className=
"title"
></
span
>
{
/* <div className="subtitle">
<span className="subtitle_bg"></span>
<span className="subtitle_text">测一测你的端午专属人设</span>
</div> */
}
<
div
className=
"turntable"
>
<
div
className=
"turntable"
>
<
span
className=
"turntable_box_bg"
></
span
>
<
span
className=
"turntable_box_bg"
></
span
>
<
CircleTurntable
<
CircleTurntable
...
...
src/pages/drawpage/drawpage.less
View file @
2df13986
...
@@ -83,32 +83,6 @@
...
@@ -83,32 +83,6 @@
position: absolute;
position: absolute;
.sparkBg("drawPage/title.png");
.sparkBg("drawPage/title.png");
}
}
.subtitle {
width: 545px;
height: 44px;
left: 99px;
top: 363px;
position: absolute;
.subtitle_bg {
width: 545px;
height: 44px;
left: 0px;
top: 0px;
position: absolute;
.sparkBg("drawPage/subtitle_bg.png");
}
.subtitle_text {
width: 411px;
height: 26px;
left: 68px;
top: 8px;
position: absolute;
font-size: 26px;
line-height: 26px;
color: rgba(255, 255, 255, 1);
text-align: center;
}
}
.turntable {
.turntable {
width: 750px;
width: 750px;
height: 843px;
height: 843px;
...
...
src/pages/homepage/homepage.jsx
View file @
2df13986
...
@@ -30,34 +30,34 @@ class Homepage extends React.Component {
...
@@ -30,34 +30,34 @@ class Homepage extends React.Component {
// 初始化首页分享信息
// 初始化首页分享信息
shareStore
.
initShareInfo
();
shareStore
.
initShareInfo
();
sensorMdExpouse
(
"activityPage"
,
{
pageName
:
"
端午
活动首页"
,
follow_action
:
1
});
sensorMdExpouse
(
"activityPage"
,
{
pageName
:
"
守护人生
活动首页"
,
follow_action
:
1
});
pageLeave
(
"
端午节活动首页点击
"
,
5
);
pageLeave
(
"
守护人生活动首页
"
,
5
);
}
}
// 我的奖品
// 我的奖品
goPrize
=
_throttle
(()
=>
{
goPrize
=
_throttle
(()
=>
{
if
(
!
store
.
checkActStatus
(
true
))
return
;
if
(
!
store
.
checkActStatus
(
true
))
return
;
sensorMdClick
(
"activityClick"
,
{
pageName
:
"
端午节活动首页点击
"
,
buttonName
:
"奖品"
});
sensorMdClick
(
"activityClick"
,
{
pageName
:
"
守护人生活动首页
"
,
buttonName
:
"奖品"
});
// store.changePage(PAGE_MAP.PRIZE_PAGE);
// store.changePage(PAGE_MAP.PRIZE_PAGE);
location
.
href
=
CFG
.
prize
;
location
.
href
=
CFG
.
prize
;
});
});
doShare
=
_throttle
(()
=>
{
doShare
=
_throttle
(()
=>
{
if
(
!
store
.
checkActStatus
())
return
;
if
(
!
store
.
checkActStatus
())
return
;
sensorMdClick
(
"activityClick"
,
{
pageName
:
"
端午节活动首页点击
"
,
buttonName
:
"分享"
});
sensorMdClick
(
"activityClick"
,
{
pageName
:
"
守护人生活动首页
"
,
buttonName
:
"分享"
});
shareStore
.
doShare
();
shareStore
.
doShare
();
});
});
openRule
=
_throttle
(()
=>
{
openRule
=
_throttle
(()
=>
{
if
(
!
store
.
checkActStatus
(
true
))
return
;
if
(
!
store
.
checkActStatus
(
true
))
return
;
sensorMdClick
(
"activityClick"
,
{
pageName
:
"
端午节活动首页点击
"
,
buttonName
:
"规则"
});
sensorMdClick
(
"activityClick"
,
{
pageName
:
"
守护人生活动首页
"
,
buttonName
:
"规则"
});
modalStore
.
pushPop
(
"Rulepop"
);
modalStore
.
pushPop
(
"Rulepop"
);
});
});
goDraw
=
_throttle
(()
=>
{
goDraw
=
_throttle
(()
=>
{
if
(
!
store
.
checkActStatus
())
return
;
if
(
!
store
.
checkActStatus
())
return
;
sensorMdClick
(
"activityClick"
,
{
pageName
:
"
端午节活动首页点击
"
,
buttonName
:
"抽奖"
});
sensorMdClick
(
"activityClick"
,
{
pageName
:
"
守护人生活动首页
"
,
buttonName
:
"抽奖"
});
store
.
changePage
(
PAGE_MAP
.
DRAW_PAGE
);
store
.
changePage
(
PAGE_MAP
.
DRAW_PAGE
);
});
});
openTask
=
_throttle
(()
=>
{
openTask
=
_throttle
(()
=>
{
if
(
!
store
.
checkActStatus
())
return
;
if
(
!
store
.
checkActStatus
())
return
;
sensorMdClick
(
"activityClick"
,
{
pageName
:
"
端午节活动首页点击
"
,
buttonName
:
"做任务"
});
sensorMdClick
(
"activityClick"
,
{
pageName
:
"
守护人生活动首页
"
,
buttonName
:
"做任务"
});
modalStore
.
pushPop
(
"Taskpop"
,
{
modalStore
.
pushPop
(
"Taskpop"
,
{
refresh
:
()
=>
store
.
getHomeInfo
(),
refresh
:
()
=>
store
.
getHomeInfo
(),
});
});
...
@@ -67,7 +67,7 @@ class Homepage extends React.Component {
...
@@ -67,7 +67,7 @@ class Homepage extends React.Component {
return
;
return
;
}
}
const
{
leftGameTimes
,
rewardDailyFreeGameTimes
}
=
store
.
homeInfo
||
{};
const
{
leftGameTimes
,
rewardDailyFreeGameTimes
}
=
store
.
homeInfo
||
{};
sensorMdClick
(
"activityClick"
,
{
pageName
:
"
端午节活动首页点击
"
,
buttonName
:
"开始测试"
});
sensorMdClick
(
"activityClick"
,
{
pageName
:
"
守护人生活动首页
"
,
buttonName
:
"开始测试"
});
if
((
Number
(
leftGameTimes
)
||
0
)
+
(
Number
(
rewardDailyFreeGameTimes
)
||
0
)
>
0
)
{
if
((
Number
(
leftGameTimes
)
||
0
)
+
(
Number
(
rewardDailyFreeGameTimes
)
||
0
)
>
0
)
{
// 进入测试页
// 进入测试页
store
.
startTest
();
store
.
startTest
();
...
@@ -92,10 +92,6 @@ class Homepage extends React.Component {
...
@@ -92,10 +92,6 @@ class Homepage extends React.Component {
<
span
className=
"test_times"
>
剩余次数:
{
(
Number
(
leftGameTimes
)
||
0
)
+
(
Number
(
rewardDailyFreeGameTimes
)
||
0
)
}
</
span
>
<
span
className=
"test_times"
>
剩余次数:
{
(
Number
(
leftGameTimes
)
||
0
)
+
(
Number
(
rewardDailyFreeGameTimes
)
||
0
)
}
</
span
>
{
/* <span className="title"></span> */
}
{
/* <span className="title"></span> */
}
<
SvgaPlayer
className=
"home_svga"
src=
{
RES_PATH
+
"svga/home.svga"
}
/>
<
SvgaPlayer
className=
"home_svga"
src=
{
RES_PATH
+
"svga/home.svga"
}
/>
{
/* <div className="subtitle">
<span className="subtitle_bg"></span>
<span className="subtitle_text">测一测你的端午专属人设</span>
</div> */
}
</
div
>
</
div
>
);
);
}
}
...
...
src/pages/homepage/homepage.less
View file @
2df13986
...
@@ -85,32 +85,6 @@
...
@@ -85,32 +85,6 @@
position: absolute;
position: absolute;
pointer-events: none;
pointer-events: none;
}
}
.subtitle {
width: 545px;
height: 44px;
left: 99px;
top: 363px;
position: absolute;
.subtitle_bg {
width: 545px;
height: 44px;
left: 0px;
top: 0px;
position: absolute;
.sparkBg("homePage/subtitle_bg.png");
}
.subtitle_text {
width: 100%;
height: 26px;
left: 0;
top: 8px;
position: absolute;
font-size: 26px;
line-height: 26px;
color: rgba(255, 255, 255, 1);
text-align: center;
}
}
.task_btn {
.task_btn {
left: 603px;
left: 603px;
top: 1260px;
top: 1260px;
...
...
src/pages/prizepage/prizepage.jsx
View file @
2df13986
...
@@ -54,7 +54,7 @@ class Prizepage extends React.Component {
...
@@ -54,7 +54,7 @@ class Prizepage extends React.Component {
navigateToPrize
=
(
item
)
=>
{
navigateToPrize
=
(
item
)
=>
{
return
_asyncThrottle
(
async
()
=>
{
return
_asyncThrottle
(
async
()
=>
{
sensorMdClick
(
"activityClick"
,
{
pageName
:
"我的奖品页
点击"
,
activityName
:
CFG
.
activityName
,
buttonName
:
`点击奖品
`
});
sensorMdClick
(
"activityClick"
,
{
pageName
:
"我的奖品页
"
,
activityName
:
CFG
.
activityName
,
buttonName
:
`奖品详情
`
});
// sensorMdClick("activityClick", { pageName: "我的奖品页", buttonName: `去看看-${item.prizeName}` });
// sensorMdClick("activityClick", { pageName: "我的奖品页", buttonName: `去看看-${item.prizeName}` });
const
{
const
{
focusStatus
,
// 是否关注公众号(true-关注,false-未关注)
focusStatus
,
// 是否关注公众号(true-关注,false-未关注)
...
@@ -94,7 +94,7 @@ class Prizepage extends React.Component {
...
@@ -94,7 +94,7 @@ class Prizepage extends React.Component {
});
});
}
}
backHome
()
{
backHome
()
{
sensorMdClick
(
"activityClick"
,
{
pageName
:
"我的奖品页
点击
"
,
buttonName
:
"返回"
,
activityName
:
CFG
.
activityName
})
sensorMdClick
(
"activityClick"
,
{
pageName
:
"我的奖品页"
,
buttonName
:
"返回"
,
activityName
:
CFG
.
activityName
})
const
fromPage
=
getUrlParam
(
'fromPage'
)
const
fromPage
=
getUrlParam
(
'fromPage'
)
if
(
fromPage
==
'home'
)
{
if
(
fromPage
==
'home'
)
{
history
.
go
(
-
1
)
history
.
go
(
-
1
)
...
...
src/pages/resultpage/resultpage.jsx
View file @
2df13986
...
@@ -41,21 +41,20 @@ class Resultpage extends React.Component {
...
@@ -41,21 +41,20 @@ class Resultpage extends React.Component {
doShare
=
_throttle
(()
=>
{
doShare
=
_throttle
(()
=>
{
sensorMdClick
(
"activityClick"
,
{
pageName
:
"结果页"
,
buttonName
:
"
分享人设
"
});
sensorMdClick
(
"activityClick"
,
{
pageName
:
"结果页"
,
buttonName
:
"
去分享
"
});
shareStore
.
doShare
();
shareStore
.
doShare
();
})
})
goDraw
=
_throttle
(()
=>
{
goDraw
=
_throttle
(()
=>
{
sensorMdClick
(
"activityClick"
,
{
pageName
:
"结果页"
,
buttonName
:
"
立即
抽奖"
});
sensorMdClick
(
"activityClick"
,
{
pageName
:
"结果页"
,
buttonName
:
"
去
抽奖"
});
store
.
changePage
(
PAGE_MAP
.
DRAW_PAGE
,
{
is_from
:
'result'
});
store
.
changePage
(
PAGE_MAP
.
DRAW_PAGE
,
{
is_from
:
'result'
});
})
})
// 查看产品详情
// 查看产品详情
openProduct
=
_throttle
((
link
)
=>
{
openProduct
=
_throttle
((
link
)
=>
{
sensorMdClick
(
"activityClick"
,
{
pageName
:
"结果页"
,
buttonName
:
"
点击
查看"
});
sensorMdClick
(
"activityClick"
,
{
pageName
:
"结果页"
,
buttonName
:
"
去
查看"
});
modalStore
.
pushPop
(
"LongImgPop2"
,
{
imgUrl
:
link
})
modalStore
.
pushPop
(
"LongImgPop2"
,
{
imgUrl
:
link
})
})
})
backHandle
=
_throttle
(()
=>
{
backHandle
=
_throttle
(()
=>
{
sensorMdClick
(
"activityClick"
,
{
pageName
:
"结果页"
,
buttonName
:
"返回"
});
store
.
changePage
(
PAGE_MAP
.
HOME_PAGE
)
store
.
changePage
(
PAGE_MAP
.
HOME_PAGE
)
})
})
...
...
src/store/index.js
View file @
2df13986
import
{
ACT_STATUS
,
ACT_STATUS_TOAST
,
PAGE_MAP
,
TOPIC_LIST
}
from
"@src/utils/constants"
;
import
{
ACT_STATUS
,
ACT_STATUS_TOAST
,
PAGE_MAP
}
from
"@src/utils/constants"
;
import
{
makeAutoObservable
}
from
"mobx"
;
import
{
makeAutoObservable
}
from
"mobx"
;
import
API
from
"../api/index"
;
import
API
from
"../api/index"
;
import
{
GetCurrSkinId
,
getCustomShareId
}
from
"@src/utils/utils"
;
import
{
GetCurrSkinId
,
getCustomShareId
}
from
"@src/utils/utils"
;
...
@@ -24,7 +24,7 @@ const store = makeAutoObservable({
...
@@ -24,7 +24,7 @@ const store = makeAutoObservable({
Did1NjA4NjM
:
PAGE_MAP
.
MID_PAGE
,
Did1NjA4NjM
:
PAGE_MAP
.
MID_PAGE
,
// 免登中间页-线上正式
// 免登中间页-线上正式
Did1NjA4NzE
:
PAGE_MAP
.
MID_PAGE
,
Did1NjA4NzE
:
PAGE_MAP
.
MID_PAGE
,
}[
skinId
]
||
PAGE_MAP
.
LIFE_SETTING
_PAGE
,
}[
skinId
]
||
PAGE_MAP
.
HOME
_PAGE
,
pageData
:
{},
pageData
:
{},
...
@@ -138,7 +138,7 @@ const store = makeAutoObservable({
...
@@ -138,7 +138,7 @@ const store = makeAutoObservable({
store
.
setUserInfo
(
res
.
data
||
{});
store
.
setUserInfo
(
res
.
data
||
{});
const
{
unionId
,
openId
,
friendEmpNo
,
friendOpenId
,
newEmpNo
}
=
res
.
data
||
{};
const
{
unionId
,
openId
,
friendEmpNo
,
friendOpenId
,
newEmpNo
}
=
res
.
data
||
{};
// initSensors(unionId, openId, friendEmpNo, friendOpenId);
// initSensors(unionId, openId, friendEmpNo, friendOpenId);
initSensors
(
unionId
,
openId
,
newEmpNo
);
initSensors
(
unionId
,
openId
,
newEmpNo
,
res
.
data
);
}
}
},
},
});
});
...
...
src/utils/constants.js
View file @
2df13986
...
@@ -174,227 +174,6 @@ export const TASK_CODE = {
...
@@ -174,227 +174,6 @@ export const TASK_CODE = {
BROWSE_MINI
:
'browse_view_mini'
,
BROWSE_MINI
:
'browse_view_mini'
,
}
}
/**
* 答题配置 共5组 每组5道题
*/
export
const
TOPIC_LIST
=
[
// 第一组
[
{
topic
:
"端午节必吃粽子,你更偏爱哪种口味?"
,
options
:
[
"甜粽派(豆沙、蜜枣)$$$a"
,
"咸粽派(蛋黄肉粽、火腿)$$$a"
,
"冰粽等创新粽子$$$c"
,
]
},
{
topic
:
"端午节时,你希望收到什么样的祝福?"
,
options
:
[
"创意满满的搞笑段子"
,
"传统又温馨的话语"
,
"简单一句“端午快乐”"
]
},
{
topic
:
"如果粽子有性格,你希望它是?"
,
options
:
[
"粽子怎么可能有性格"
,
"热情似火的小太阳"
,
"古灵精怪的小精灵"
]
},
{
topic
:
"假如端午假期和朋友约饭,你选?"
,
options
:
[
"亲自为朋友做粽子盛情款待$$$e"
,
"找家网红餐厅尝鲜"
,
"在家等朋友投喂"
]
},
{
topic
:
"端午节一些地方会举办爬龙舟比赛,你想?"
,
options
:
[
"亲自下场,感受速度激情$$$b"
,
"岸边助威,当最强气氛组"
,
"线上围观,不想出门凑热闹$$$d"
]
},
],
// 第二组
[
{
topic
:
"当听说有的地方端午用雄黄酒在小孩额头写“王”字,你?"
,
options
:
[
"觉得很有趣,想给孩子试试$$$c"
,
"新奇,但不会轻易尝试"
,
"这操作有点迷,不太理解"
]
},
{
topic
:
"端午期间,你愿意花时间学编五彩绳吗?"
,
options
:
[
"必须的,编好送亲友多有面$$$a"
,
"可以试试,毕竟是传统文化$$$a"
,
"太麻烦了,直接买现成的$$$d"
]
},
{
topic
:
"端午节你会邀请朋友来家里吗?"
,
options
:
[
"肯定会,组织一场热闹的聚会$$$b"
,
"看情况,有时间就邀请$$$a"
,
"不会,喜欢自己过节"
]
},
{
topic
:
" 假如粽子会上网,它发的第一条动态会是?"
,
options
:
[
"“家人们谁懂啊,被包得好紧”"
,
"“今天和隔壁月饼battle了一下人气”"
,
"“谁来尝尝我的新馅料,绝了”"
]
},
{
topic
:
"对于粽子的搭配,你有研究吗?"
,
options
:
[
"会研究各种新奇搭配和茶点$$$e"
,
"随便搭配,能吃就行"
,
"没有,就正常吃粽子"
]
},
],
// 第三组
[
{
topic
:
"你觉得端午节吃粽子,什么最重要?"
,
options
:
[
"必须是独特的口味"
,
"精致好看的外形"
,
"亲手制作的心意"
]
},
{
topic
:
"端午节公司搞活动,你希望是?"
,
options
:
[
"包粽子大赛,展示自己的手艺$$$e"
,
"粽子创意摆盘比赛,看谁脑洞大"
,
"放假一天,在家躺平"
]
},
{
topic
:
"有些地方端午节有“躲午”的习俗,你怎么看?"
,
options
:
[
"很有意思,想了解更多"
,
"不太理解,感觉没必要"
,
"尊重习俗,但不参与"
]
},
{
topic
:
"假如有个粽子博物馆,你觉得里面会有?"
,
options
:
[
"从古至今各种传统粽子模具,展示历史$$$a"
,
"世界各地奇葩粽子的标本,大开眼界$$$c"
,
"休息区,逛累了可以吃粽子$$$d"
]
},
{
topic
:
"朋友邀请你参加端午节户外活动,你会?"
,
options
:
[
"马上答应,还主动帮忙策划$$$b"
,
"犹豫一下,看自己的安排"
,
"找借口拒绝,想在家休息"
]
},
],
// 第四组
[
{
topic
:
"端午节一些地区有“送时节”的习俗,你知道是指?"
,
options
:
[
"送应季礼品走亲访友"
,
"给亲朋好友送祝福"
,
"不太清楚,没听说过"
]
},
{
topic
:
"假如端午节有专属宠物装扮,你会给宠物?"
,
options
:
[
"精心打扮,拍照发圈$$$c"
,
"偶尔试试,图个乐呵"
,
"算了,感觉很麻烦"
]
},
{
topic
:
"假如粽子会唱歌,你觉得它会唱?"
,
options
:
[
"《最炫民族风》,经典永不褪色"
,
"《卡路里》,吃了不怕胖"
,
"《无所谓》,和自己的心态一样"
]
},
{
topic
:
"端午当天,你会选择什么活动?"
,
options
:
[
"观看传统的龙舟比赛,感受古老的竞技氛围$$$a"
,
"看看电视里的端午节目,轻松度过$$$d"
,
"参加粽子品鉴会,品尝各地特色粽子$$$e"
]
},
{
topic
:
"端午节在社交平台,你:"
,
options
:
[
"频繁发动态,邀请大家线下玩$$$b"
,
"偶尔发一条祝福动态"
,
"基本不看也不发动态"
]
},
],
// 第五组
[
{
topic
:
"端午节时,你会选择哪种方式放松?"
,
options
:
[
"泡个艾草澡,舒缓身心"
,
"DIY端午美食,招待好友$$$e"
,
"和朋友逛街喝咖啡"
]
},
{
topic
:
"你觉得端午节的龙舟竞渡,最吸引人的是?"
,
options
:
[
"紧张刺激的比赛氛围"
,
"独特的龙舟造型和装饰"
,
"大家齐心协力的团队精神"
]
},
{
topic
:
"看到商家推出的端午限定产品,你会?"
,
options
:
[
"选择具有传统特色的产品,支持传统文化$$$a"
,
"买一些和朋友分享,增加节日氛围$$$b"
,
"购买最有创意、最新奇的限定产品$$$c"
]
},
{
topic
:
"假如粽子拥有超能力,你希望它具备什么神奇技能?"
,
options
:
[
"能自己包自己,还能变出各种馅料"
,
"能瞬间变成各种新奇口味,永远吃不腻"
,
"不需要什么技能,随遇而安就好$$$d"
]
},
{
topic
:
"如果你穿越成屈原,你会?"
,
options
:
[
"举办第一届粽子品鉴大会"
,
"把离骚改编成说唱,宣传端午"
,
"先找个地方好好睡一觉,太操心了"
]
},
],
]
/**
/**
* 人设信息
* 人设信息
*/
*/
...
...
src/utils/sensorMd.js
View file @
2df13986
...
@@ -4,7 +4,7 @@ import sensors from 'sa-sdk-javascript';
...
@@ -4,7 +4,7 @@ import sensors from 'sa-sdk-javascript';
import
{
ACTIVITY_SOURCE_CHANNEL
,
SYS_SOURCE_CHANNEL
}
from
'./constants'
;
import
{
ACTIVITY_SOURCE_CHANNEL
,
SYS_SOURCE_CHANNEL
}
from
'./constants'
;
import
pageleave
from
'./pageleave'
;
import
pageleave
from
'./pageleave'
;
export
const
initSensors
=
(
uid
,
openId
,
newEmpNo
,
friendOpenId
)
=>
{
export
const
initSensors
=
(
uid
,
openId
,
newEmpNo
,
userInfo
)
=>
{
sensors
.
init
({
sensors
.
init
({
server_url
:
CFG
.
sensorUrl
,
server_url
:
CFG
.
sensorUrl
,
is_track_single_page
:
true
,
is_track_single_page
:
true
,
...
@@ -31,13 +31,15 @@ export const initSensors = (uid, openId, newEmpNo, friendOpenId) => {
...
@@ -31,13 +31,15 @@ export const initSensors = (uid, openId, newEmpNo, friendOpenId) => {
const
publicObjec
=
objectAssign
({
const
publicObjec
=
objectAssign
({
currentUrl
:
location
.
href
,
currentUrl
:
location
.
href
,
referrer
:
document
.
referrer
,
referrer
:
document
.
referrer
,
activityId
:
"25
DragonBoat
"
,
activityId
:
"25
GuardingLife
"
,
unionid
:
uid
,
unionid
:
uid
,
openid
:
openId
,
openid
:
openId
,
source
:
CFG
.
channel
,
source
:
CFG
.
channel
,
systemName
:
'寿险2013版微信公众平台'
,
systemName
:
'寿险2013版微信公众平台'
,
userSource
:
null
,
userAccount
:
CFG
.
channel
==
'taihaodian'
?
'太好店小程序'
:
'太平洋寿险小程序'
,
activityName
:
CFG
.
activityName
,
activityName
:
CFG
.
activityName
,
c_date
:
"2025/
5/19-2025/6/13
"
,
c_date
:
"2025/
08/01-2025/08/24
"
,
empNp
:
newEmpNo
,
// 用户实际绑定业务员工号(与转发无关)
empNp
:
newEmpNo
,
// 用户实际绑定业务员工号(与转发无关)
activitySource
:
ACTIVITY_SOURCE_CHANNEL
[
CFG
.
channel
]
||
""
,
activitySource
:
ACTIVITY_SOURCE_CHANNEL
[
CFG
.
channel
]
||
""
,
sysSourceName
:
SYS_SOURCE_CHANNEL
[
CFG
.
channel
]
||
""
,
sysSourceName
:
SYS_SOURCE_CHANNEL
[
CFG
.
channel
]
||
""
,
...
@@ -45,8 +47,25 @@ export const initSensors = (uid, openId, newEmpNo, friendOpenId) => {
...
@@ -45,8 +47,25 @@ export const initSensors = (uid, openId, newEmpNo, friendOpenId) => {
shareMark
:
!!
getUrlParam
(
"uid"
)
?
"是"
:
"否"
,
shareMark
:
!!
getUrlParam
(
"uid"
)
?
"是"
:
"否"
,
shareType
:
shareType
,
shareType
:
shareType
,
friendEmpNo
:
getUrlParam
(
"shareNewEmpNo"
),
// 邀请人的业务员工号(A转发给B,传A的业务员工号)
friendEmpNo
:
getUrlParam
(
"shareNewEmpNo"
),
// 邀请人的业务员工号(A转发给B,传A的业务员工号)
friendOpenId
:
getUrlParam
(
"shareOpenId"
),
// 邀请人的openId
friendOpenId
:
getUrlParam
(
"shareOpenId"
),
// 邀请人的openId
empno
:
CFG
.
empno
empno
:
CFG
.
empno
,
miniopenid
:
userInfo
?.
miniopenid
||
''
,
phone
:
userInfo
?.
phone
||
''
,
wxNickName
:
userInfo
?.
nickname
||
''
,
sex
:
userInfo
?.
sex
||
''
,
age
:
userInfo
?.
age
||
''
,
userLevel
:
userInfo
?.
userLevel
||
''
,
subscribeFlg
:
userInfo
?.
subscribeFlg
||
false
,
subscribeFlg2
:
userInfo
?.
subscribeFlg2
||
false
,
officerOrEmp
:
userInfo
?.
officerOrEmp
||
''
,
programLogin
:
userInfo
?.
programLogin
||
''
,
province
:
userInfo
?.
province
||
''
,
memberAttribution
:
userInfo
?.
memberAttribution
||
''
,
memberType
:
userInfo
?.
memberType
||
''
,
memberLevel
:
userInfo
?.
customLevel
||
''
,
},
window
[
'__tbSensorsObj__'
]);
},
window
[
'__tbSensorsObj__'
]);
sensors
.
registerPage
(
publicObjec
);
sensors
.
registerPage
(
publicObjec
);
sensors
.
quick
(
'autoTrack'
);
sensors
.
quick
(
'autoTrack'
);
...
...
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