Commit e174e0f4 authored by Mac's avatar Mac

修改

parent 6bf1af19
This diff is collapsed.
......@@ -5,10 +5,16 @@
<u-swiper :list="imgsList" :effect3d="false" :height="700" :interval="5000" :border-radius="0"
@click="previewImage" name="url" v-if="active==1"></u-swiper>
<view style="background-color: #111;height: 700rpx;position: relative;" v-if="active==0">
<image
<!-- <image
src="https://viitto-1301420277.cos.ap-chengdu.myqcloud.com/Test/Upload/Goods/1616398636000_211.png"
style="width: 100%;height: 100%;" mode="aspectFill"></image>
<view
style="width: 100%;height: 100%;" mode="aspectFill"></image> -->
<video id="myVideo" :src="files" style="width: 100%;height: 100%;"
:controls='controls'
:show-center-play-btn='false'
:show-fullscreen-btn='false'
@fullscreenchange='videoControl'
></video>
<view @click="enlarge(files)"
style="position: absolute;left: 50%;top: 50%;margin-top: -49rpx;margin-left: -49rpx;width: 98rpx;height: 98rpx;border-radius: 20rpx;background-color: rgba(255,255,255,.4);display: flex;align-items: center;justify-content: center;">
<image
src="https://viitto-1301420277.cos.ap-chengdu.myqcloud.com/Test/Upload/Goods/1616471847000_345.png"
......@@ -190,6 +196,8 @@
active: 0,
mainColor: '',
likeStatus: false,
controls:false,//显示默认控件
files:'https://viitto-1301420277.cos.ap-chengdu.myqcloud.com/SaleBefore/Goods/637515953765903034.mp4',
}
},
onLoad(options) {
......@@ -259,7 +267,24 @@
name,
address:"武侯区科华中路 2 号"
})
}
},
enlarge(file) {
// 全屏
this.videoContext = uni.createVideoContext('myVideo');
this.videoContext.requestFullScreen({
direction:0
})
},
videoControl(e){
if(e.detail.fullScreen==false){
this.videoContext.stop()
this.controls=false
}else{
this.videoContext.play()
this.controls=true
}
},
}
}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment