merge..
This commit is contained in:
@@ -105,7 +105,7 @@ Page({
|
||||
stepsCount: 0, // 默认分几个步骤
|
||||
currentSteps: 0, // 当前默认是第几步
|
||||
currentTime: 0, // 当前总时长
|
||||
remainingTime: 0, // 播放时间
|
||||
remainingTime: '00', // 播放时间
|
||||
},
|
||||
videoContext: null,
|
||||
seeAllVideo: true,
|
||||
@@ -135,22 +135,21 @@ Page({
|
||||
let selectVideoItem = this.data.selectVideoItem
|
||||
let currentTimeEnd = selectVideoItem.steps[selectVideoItem.currentSteps].endTime
|
||||
let {
|
||||
currentTime
|
||||
currentTime,duration
|
||||
} = e.detail
|
||||
if (currentTime > currentTimeEnd && selectVideoItem.currentSteps < selectVideoItem.stepsCount) {
|
||||
selectVideoItem.currentSteps++
|
||||
|
||||
this.videoContext.pause()
|
||||
// 倒计时且有提醒
|
||||
setTimeout(() => {
|
||||
this.videoContext.play()
|
||||
}, 3000);
|
||||
}
|
||||
// 第一次初始化
|
||||
// let startCountDown = selectVideoItem.steps[selectVideoItem.currentSteps].startCountDown
|
||||
// if(!selectVideoItem.remainingTime &&selectVideoItem.currentSteps!=this.data.selectVideoItem.currentSteps){
|
||||
// let remainingTime=parseInt(currentTimeEnd - startCountDown) >=10 ? parseInt(currentTimeEnd -startCountDown):'0' + parseInt(currentTimeEnd -startCountDown)
|
||||
// selectVideoItem.remainingTime = remainingTime
|
||||
// }
|
||||
// 递减
|
||||
// if (currentTime >= startCountDown) {
|
||||
let remainingTime = parseInt(currentTimeEnd - currentTime) >= 10 ? parseInt(currentTimeEnd - currentTime) : '0' + parseInt(currentTimeEnd - currentTime)
|
||||
selectVideoItem.remainingTime = remainingTime
|
||||
// }
|
||||
|
||||
let remainingTime = parseInt(duration - currentTime) >= 10 ? parseInt(duration - currentTime) : '0' + parseInt(duration - currentTime)
|
||||
selectVideoItem.remainingTime = remainingTime
|
||||
|
||||
this.setData({
|
||||
selectVideoItem: selectVideoItem
|
||||
})
|
||||
|
||||
@@ -61,6 +61,11 @@ Page({
|
||||
mask :true,
|
||||
duration:2000
|
||||
})
|
||||
setTimeout(()=>{
|
||||
this.setData({
|
||||
loading:false
|
||||
})
|
||||
},3000)
|
||||
})
|
||||
},
|
||||
onPullDownRefresh(){
|
||||
|
||||
@@ -62,8 +62,8 @@ page {
|
||||
margin-right: 20rpx;
|
||||
margin-bottom: 20rpx;
|
||||
border-radius: 10rpx;
|
||||
width: calc(100vw/3 - 20px);
|
||||
height: calc(100vw/3 - 20px);
|
||||
width: calc(100vw/3 - 34px);
|
||||
height: calc(100vw/3 - 34px);
|
||||
}
|
||||
|
||||
.cont-img-list2{
|
||||
@@ -78,8 +78,8 @@ page {
|
||||
margin-right: 20rpx;
|
||||
margin-bottom: 20rpx;
|
||||
border-radius: 10rpx;
|
||||
width: calc(100vw/2.2 - 20px);
|
||||
height: calc(100vw/2.2 - 20px);
|
||||
width: calc(100vw/2.2 - 30px);
|
||||
height: calc(100vw/2.2 - 30px);
|
||||
}
|
||||
|
||||
.cont-video{
|
||||
|
||||
Reference in New Issue
Block a user