Skip to content
项目
群组
代码片段
帮助
正在加载...
帮助
提交反馈
为 GitLab 提交贡献
登录
切换导航
Y
year-end-activitiy
项目
项目
详情
动态
版本
周期分析
仓库
仓库
文件
提交
分支
标签
贡献者
分支图
比较
统计图
议题
0
议题
0
列表
看板
标记
里程碑
合并请求
0
合并请求
0
CI / CD
CI / CD
流水线
作业
计划
统计图
Wiki
Wiki
代码片段
代码片段
成员
成员
收起侧边栏
Close sidebar
动态
分支图
统计图
创建新议题
作业
提交
议题看板
打开侧边栏
com.pica.cloud.foundation.frontend
year-end-activitiy
提交
5409c0b5
提交
5409c0b5
编写于
12月 05, 2019
作者:
tao.wu
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
修改分享参数
上级
8f9a14c6
变更
4
显示空白字符变更
内嵌
并排
正在显示
4 个修改的文件
包含
24 行增加
和
25 行删除
+24
-25
wxShare.js
configs/wxShare.js
+6
-0
in-activity.vue
pages/in-activity.vue
+2
-8
shareActive.vue
pages/shareActive.vue
+7
-9
shareResult.vue
pages/shareResult.vue
+9
-8
未找到文件。
configs/wxShare.js
0 → 100644
浏览文件 @
5409c0b5
export
const
wxShare
=
{
shareUrl
:
''
,
title1
:
'您的好友邀请您领取医学课程'
,
title2
:
'参与云鹊奖活动,领取免费课程,赢取iphone11等丰厚奖品'
,
shareImageUrl
:
'https://file.yunqueyi.com/h5/nzhd19/share2.png'
}
\ No newline at end of file
pages/in-activity.vue
浏览文件 @
5409c0b5
...
@@ -223,9 +223,9 @@
...
@@ -223,9 +223,9 @@
import
{
Toast
}
from
'vant'
;
import
{
Toast
}
from
'vant'
;
import
{
setEventByModuleCode
,
getFirstAwards
}
from
'@/utils'
;
import
{
setEventByModuleCode
,
getFirstAwards
}
from
'@/utils'
;
import
{
ENV_CONFIG
}
from
'@/utils/enumerate'
;
import
{
ENV_CONFIG
}
from
'@/utils/enumerate'
;
import
{
wxShare
}
from
'@/configs/wxShare'
;
const
cookies
=
require
(
'cookie-universal'
)();
const
cookies
=
require
(
'cookie-universal'
)();
let
vm
=
null
;
let
vm
=
null
;
export
default
{
export
default
{
data
()
{
data
()
{
...
@@ -303,12 +303,7 @@
...
@@ -303,12 +303,7 @@
id
:
''
,
id
:
''
,
},
},
isWeb
:
false
,
isWeb
:
false
,
shareObj
:
{
shareObj
:
wxShare
,
shareUrl
:
''
,
title1
:
'您的好友邀请您领取医学课程'
,
title2
:
'参与云鹊奖活动,领取免费课程,赢取iphone11等丰厚奖品'
,
shareImageUrl
:
'https://file.yunqueyi.com/h5/nzhd19/share2.png'
},
padTop
:
0
padTop
:
0
}
}
},
},
...
@@ -360,7 +355,6 @@
...
@@ -360,7 +355,6 @@
// vm.getTasks();
// vm.getTasks();
// // 这里需要删掉!!!
// // 这里需要删掉!!!
vm
.
isWeb
=
vm
.
$rocNative
.
isWeb
;
vm
.
isWeb
=
vm
.
$rocNative
.
isWeb
;
// vm.shareObj.shareUrl = `${getShareUrl()}year_end_ssr/shareActive?id=${vm.encryptId}&taskId=${vm.eachInviteAward.taskId}&activityId=${vm.eachInviteAward.activityId}`
// 取服务器时间,切换不同时间段的显示
// 取服务器时间,切换不同时间段的显示
vm
.
getServerTime
();
vm
.
getServerTime
();
...
...
pages/shareActive.vue
浏览文件 @
5409c0b5
...
@@ -54,6 +54,7 @@
...
@@ -54,6 +54,7 @@
<
script
>
<
script
>
import
{
getInviteInfo
,
getCourseById
,
getCaptchaGet
,
getAuthCode
}
from
'@/service'
;
import
{
getInviteInfo
,
getCourseById
,
getCaptchaGet
,
getAuthCode
}
from
'@/service'
;
import
{
wxShare
}
from
'@/configs/wxShare'
;
const
TIMEALL
=
60000
;
// 倒计时常量 60 秒
const
TIMEALL
=
60000
;
// 倒计时常量 60 秒
export
default
{
export
default
{
data
(){
data
(){
...
@@ -68,7 +69,8 @@
...
@@ -68,7 +69,8 @@
captchaAnswer
:
''
,
// 输入的图形验证码
captchaAnswer
:
''
,
// 输入的图形验证码
time
:
TIMEALL
,
time
:
TIMEALL
,
btnMsg
:
'点击获取'
,
btnMsg
:
'点击获取'
,
isReq
:
false
isReq
:
false
,
shareObj
:
wxShare
,
}
}
},
},
async
asyncData
({
query
}){
async
asyncData
({
query
}){
...
@@ -93,17 +95,13 @@
...
@@ -93,17 +95,13 @@
document
.
querySelector
(
'body'
).
setAttribute
(
'style'
,
'background: #FE9A51;'
);
document
.
querySelector
(
'body'
).
setAttribute
(
'style'
,
'background: #FE9A51;'
);
this
.
checkCache
();
this
.
checkCache
();
// 微信分享
// 微信分享
this
.
shareObj
=
{
this
.
shareObj
.
shareUrl
=
window
.
location
.
href
;
shareUrl
:
window
.
location
.
href
,
window
.
localStorage
.
setItem
(
'shareUrl'
,
this
.
shareObj
.
shareUrl
);
title1
:
'分享title分享title'
,
title2
:
'分享desc分享desc'
,
shareImageUrl
:
'https://file.yunqueyi.com/h5/nzhd19/share.png'
}
this
.
$picaWxShare
({
this
.
$picaWxShare
({
// baseUrl: BASE_URL[process.env.NUXT_ENV_APP],
// baseUrl: BASE_URL[process.env.NUXT_ENV_APP],
baseUrl
:
'https://test1-sc.yunqueyi.com'
,
baseUrl
:
'https://test1-sc.yunqueyi.com'
,
type
:
15
,
type
:
15
,
authUrl
:
window
.
location
.
href
,
authUrl
:
this
.
shareObj
.
shareUrl
,
isDebug
:
false
,
isDebug
:
false
,
jsApiList
:
[
jsApiList
:
[
'onMenuShareTimeline'
,
'onMenuShareTimeline'
,
...
@@ -112,7 +110,7 @@
...
@@ -112,7 +110,7 @@
},(
wx
)
=>
{
},(
wx
)
=>
{
const
title
=
this
.
shareObj
.
title1
;
const
title
=
this
.
shareObj
.
title1
;
const
desc
=
this
.
shareObj
.
title2
;
const
desc
=
this
.
shareObj
.
title2
;
const
link
=
window
.
location
.
href
;
const
link
=
this
.
shareObj
.
shareUrl
;
const
imgUrl
=
this
.
shareObj
.
shareImageUrl
;
const
imgUrl
=
this
.
shareObj
.
shareImageUrl
;
// 分享给朋友
// 分享给朋友
wx
.
onMenuShareAppMessage
({
wx
.
onMenuShareAppMessage
({
...
...
pages/shareResult.vue
浏览文件 @
5409c0b5
...
@@ -53,6 +53,7 @@
...
@@ -53,6 +53,7 @@
</
template
>
</
template
>
<
script
>
<
script
>
import
{
wxShare
}
from
'@/configs/wxShare'
;
export
default
{
export
default
{
asyncData
({
query
}){
asyncData
({
query
}){
const
{
status
}
=
query
;
// 上个页面传递过来领取结果, false 为已领取, true 为领取成功
const
{
status
}
=
query
;
// 上个页面传递过来领取结果, false 为已领取, true 为领取成功
...
@@ -61,20 +62,20 @@
...
@@ -61,20 +62,20 @@
statusTxt
statusTxt
}
}
},
},
data
(){
return
{
shareObj
:
wxShare
,
}
},
mounted
(){
mounted
(){
document
.
querySelector
(
'body'
).
setAttribute
(
'style'
,
'background: "";'
);
document
.
querySelector
(
'body'
).
setAttribute
(
'style'
,
'background: "";'
);
// 微信分享
// 微信分享
this
.
shareObj
=
{
this
.
shareObj
.
shareUrl
=
window
.
localStorage
.
getItem
(
'shareUrl'
)
||
window
.
location
.
href
;
shareUrl
:
window
.
location
.
href
,
title1
:
'分享title分享title'
,
title2
:
'分享desc分享desc'
,
shareImageUrl
:
'https://file.yunqueyi.com/h5/nzhd19/share.png'
}
this
.
$picaWxShare
({
this
.
$picaWxShare
({
// baseUrl: BASE_URL[process.env.NUXT_ENV_APP],
// baseUrl: BASE_URL[process.env.NUXT_ENV_APP],
baseUrl
:
'https://test1-sc.yunqueyi.com'
,
baseUrl
:
'https://test1-sc.yunqueyi.com'
,
type
:
15
,
type
:
15
,
authUrl
:
window
.
location
.
href
,
authUrl
:
this
.
shareObj
.
shareUrl
,
isDebug
:
false
,
isDebug
:
false
,
jsApiList
:
[
jsApiList
:
[
'onMenuShareTimeline'
,
'onMenuShareTimeline'
,
...
@@ -83,7 +84,7 @@
...
@@ -83,7 +84,7 @@
},(
wx
)
=>
{
},(
wx
)
=>
{
const
title
=
this
.
shareObj
.
title1
;
const
title
=
this
.
shareObj
.
title1
;
const
desc
=
this
.
shareObj
.
title2
;
const
desc
=
this
.
shareObj
.
title2
;
const
link
=
window
.
location
.
href
;
const
link
=
this
.
shareObj
.
shareUrl
;
const
imgUrl
=
this
.
shareObj
.
shareImageUrl
;
const
imgUrl
=
this
.
shareObj
.
shareImageUrl
;
// 分享给朋友
// 分享给朋友
wx
.
onMenuShareAppMessage
({
wx
.
onMenuShareAppMessage
({
...
...
写
预览
Markdown
格式
0%
请重试
or
附加一个文件
附加文件
取消
您添加了
0
人
到此讨论。请谨慎行事。
先完成此消息的编辑!
取消
想要评论请
注册
或
登录