Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
U
uniapp_vedio
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
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
android
uniapp_vedio
Commits
6b6bf237
Commit
6b6bf237
authored
Jun 05, 2024
by
jyx
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
添加看广告逻辑
parent
c3f6b8e2
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
15 additions
and
7 deletions
+15
-7
task.vue
vedio/pagesA/task/task.vue
+15
-7
No files found.
vedio/pagesA/task/task.vue
View file @
6b6bf237
...
...
@@ -149,7 +149,7 @@
success
()
{
message
.
notify
(
'分享成功'
);
if
(
that
.
signData
.
list
[
signData
.
todayMsgIndexInWeek
].
rewardMoreType
)
{
that
.
reportTaskPointMore
(
that
.
signData
.
list
[
signData
.
todayMsgIndexInWeek
]
,
true
)
that
.
reportTaskPointMore
(
that
.
signData
.
list
[
signData
.
todayMsgIndexInWeek
])
}
},
fail
()
{
...
...
@@ -179,14 +179,18 @@
// 预加载资源
this
.
ad
.
load
();
},
showAd
(
item
)
{
showAd
(
item
,
isSign
)
{
this
.
ad
.
show
();
let
that
=
this
// 监听视频播放完成
this
.
ad
.
onClose
((
data
)
=>
{
tt
.
hideLoading
();
if
(
data
.
isEnded
)
{
that
.
reportTaskPointMore
(
item
,
true
)
if
(
isSign
)
{
that
.
reportTaskPointMore
(
item
)
}
else
{
that
.
reportCompleteTask
(
item
.
taskId
)
}
}
else
{
message
.
notify
(
'未观看完视频'
);
}
...
...
@@ -309,7 +313,7 @@
},
});
},
reportTaskPointMore
(
item
,
isSign
)
{
reportTaskPointMore
(
item
)
{
// 领取奖励
let
that
=
this
...
...
@@ -355,9 +359,13 @@
})
},
doTask
(
item
)
{
console
.
log
(
item
)
if
(
item
.
status
==
2
)
{
if
(
item
.
status
==
3
)
{
// 已领取金币
message
.
notify
(
'请稍后再试'
)
return
}
else
if
(
item
.
status
==
2
)
{
// 已领取金币
message
.
notify
(
'已领取金币'
)
return
}
else
if
(
item
.
status
==
1
)
{
// 已完成任务,领取看点
...
...
@@ -401,7 +409,7 @@
item
.
listCode
==
TaskConstant
.
seeAd
)
{
// TODO 看广告
this
.
showAd
(
item
,
false
)
}
else
{
redirectTo
(
`/pages/home`
)
}
...
...
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