zhgdyunapp/pages/projectEnd/workTicketManage/historicalReplayVideo.vue

172 lines
3.2 KiB
Vue

<template>
<view class="addIssue">
<view class="fixedheader">
<headers :showBack="true">
<view class="headerName">
历史回放
</view>
</headers>
</view>
<view class="content" :style="{paddingTop: mobileTopHeight + 44 + 'px'}">
<video id="myVideo" :src="url_config + 'image/' + policeCameraItemFileInfo.fileUrl" controls></video>
<view class="content_time">
<view>有效时长</view>
<view>{{policeCameraItemFileInfo.startTime}} ~ {{policeCameraItemFileInfo.endTime}}</view>
</view>
</view>
</view>
</template>
<script>
export default {
data() {
return {
mobileTopHeight: 0,
projectDetail: {},
historyId:"",
policeCameraItemFileInfo:{},
}
},
onLoad(opts) {
this.projectDetail = JSON.parse(uni.getStorageSync('projectDetail'));
this.historyId = opts.id;
this.getWorkTicketHistoryQueryByIdFn();
},
mounted() {
var that = this
uni.getSystemInfo({
success(res) {
that.mobileTopHeight = res.statusBarHeight ? res.statusBarHeight : 0;
uni.setStorageSync('systemInfo', res)
console.log(res)
}
})
},
methods: {
// 通过id查询执法记录仪文件信息
getWorkTicketHistoryQueryByIdFn() {
let that = this;
let data = {
projectSn: this.projectDetail.projectSn,
id: this.historyId,
};
this.sendRequest({
url: 'xmgl/policeCameraItemFile/queryById',
method: 'GET',
data: data,
success: res => {
if (res.code == 200) {
that.policeCameraItemFileInfo = res.result;
}
}
})
},
},
}
</script>
<style scoped lang="scss">
.addIssue {
min-height: 100vh;
background-color: white;
}
.content {
video {
width: 100vw;
height: 420rpx;
}
.content_time {
padding: 26rpx;
display: flex;
align-items: center;
> view:first-child {
font-size: 28rpx;
color: #4D4D4D;
}
> view:last-child {
font-weight: 500;
font-size: 28rpx;
color: #4D4D4D;
margin-left: 20rpx;
}
}
}
.fixedheader {
position: fixed;
top: 0;
left: 0;
width: 100%;
z-index: 999;
/deep/ .headerBox {
border-bottom: none;
}
.headerName {
z-index: 1;
}
}
.search-box {
background-color: white;
width: 100%;
padding: 26rpx;
position: fixed;
z-index: 99;
>view:last-child {
font-weight: 500;
font-size: 28rpx;
color: #4D4D4D;
margin-top: 10rpx;
}
>view:first-child {
display: flex;
align-items: center;
justify-content: space-between;
>view:first-child {
font-size: 28rpx;
color: #4D4D4D;
}
>view:last-child {
padding: 6rpx 20rpx;
background-color: rgba(75, 141, 236, 0.1);
border-radius: 76rpx 76rpx 76rpx 76rpx;
border: 2rpx solid #FFFFFF;
font-size: 21rpx;
color: #4B8DEC;
}
}
}
.new-nodata {
position: absolute;
top: 50%;
left: 50%;
transform: translate(-50%, -50%);
display: flex;
flex-direction: column;
align-items: center;
justify-content: center;
>view {
width: 300rpx;
height: 300rpx;
background-image: url('@/static/staffAttendance/nodata.png');
background-repeat: no-repeat;
background-size: 100% 100%;
}
>text {
font-size: 22rpx;
color: #808080;
margin-top: 60rpx;
}
}
</style>