Merge branch 'bjxz-dev' of http://139.9.66.234:18023/dhp/zhgdyunapp into bjxz-dev

This commit is contained in:
Vce 2024-05-16 18:21:48 +08:00
commit 1f57db9c78
3 changed files with 35 additions and 21 deletions

View File

@ -38,9 +38,9 @@ if (process.env.NODE_ENV === 'development') {
// Vue.prototype.url_config = 'http://47.93.215.234:9809/' // 鞍钢正式地址(弃用) // Vue.prototype.url_config = 'http://47.93.215.234:9809/' // 鞍钢正式地址(弃用)
// Vue.prototype.url_config = 'http://42.180.188.17:9809/' // 鞍钢正式地址 // Vue.prototype.url_config = 'http://42.180.188.17:9809/' // 鞍钢正式地址
// Vue.prototype.url_config = 'http://42.180.188.17:11211/' // 鞍钢测试地址 // Vue.prototype.url_config = 'http://42.180.188.17:11211/' // 鞍钢测试地址
Vue.prototype.url_config = 'http://182.90.224.237:51234/' //雄哥内网穿透地址 // Vue.prototype.url_config = 'http://182.90.224.237:51234/' //雄哥内网穿透地址
// Vue.prototype.url_config = 'http://jxj.zhgdyun.com:61212/' //杰哥内网穿透地址 // Vue.prototype.url_config = 'http://jxj.zhgdyun.com:61212/' //杰哥内网穿透地址
// Vue.prototype.url_config = 'http://192.168.34.221:9111/' //郭圣雄本地 Vue.prototype.url_config = 'http://192.168.34.221:9111/' //郭圣雄本地
// Vue.prototype.url_config = 'http://192.168.34.155:19111/' //彭洁本地 // Vue.prototype.url_config = 'http://192.168.34.155:19111/' //彭洁本地
// Vue.prototype.work_url = 'http://47.93.215.234:19997' // 工作流线上地址(弃用) // Vue.prototype.work_url = 'http://47.93.215.234:19997' // 工作流线上地址(弃用)
// Vue.prototype.work_url = 'http://42.180.188.17:19997' // 工作流线上地址 // Vue.prototype.work_url = 'http://42.180.188.17:19997' // 工作流线上地址

View File

@ -49,16 +49,16 @@
pageType: 'company', pageType: 'company',
pageNo: 1, pageNo: 1,
pageSize: 7, pageSize: 7,
timeRange: [] timeRange: [],
pageSupportData: {}
}; };
}, },
onLoad(options) { onLoad(options) {
console.log(options) console.log(options)
if (options.pageType) { this.pageSupportData = JSON.parse(options.obj)
this.pageType = options.pageType console.log(this.pageSupportData)
}
// this.loadData(options.sn)
this.pageNo = 1; this.pageNo = 1;
this.loadData()
}, },
onReachBottom() { onReachBottom() {
// console.log("============================") // console.log("============================")
@ -66,14 +66,13 @@
uni.showLoading({ uni.showLoading({
title: '加载中' title: '加载中'
}) })
// this.loadData() this.loadData()
}, },
methods: { methods: {
confirmTimeRange(e, index) { confirmTimeRange(e, index) {
console.log(e, index) console.log(e, index)
// this.form.plannedMakeBeamBeginTime = e[0] this.timeRange = e;
// this.form.plannedMakeBeamEndTime = e[1] this.loadData();
// console.log("", e)
}, },
playVideoFn(item) { playVideoFn(item) {
uni.navigateTo({ uni.navigateTo({
@ -81,17 +80,20 @@
}) })
}, },
// //
loadData(sn) { loadData() {
var that = this var that = this
console.log(this.timeRange,777888)
let requestData = {
projectSn: that.pageSupportData.projectSn,
serialNumber: that.pageSupportData.serialNumber
}
if(this.timeRange && this.timeRange.length > 0){
requestData.beginTime = this.timeRange[0]
requestData.endTime = this.timeRange[1]
}
this.sendRequest({ this.sendRequest({
url: "xmgl/videoItem/callPostPlaybackURLsV2", url: "xmgl/videoItem/callPostPlaybackURLsV2",
data: { data: requestData,
projectSn: sn,
projectSn: "BD3137498CB84BF0969979E0342CDBCA",
serialNumber: "0f74ac52cf0e40af84be654242b55ac7",
beginTime: "2024-05-16 00:00:00",
endTime: "2024-05-16 17:00:00"
},
method: "POST", method: "POST",
success(res) { success(res) {
console.log('找封面', res) console.log('找封面', res)

View File

@ -7,7 +7,7 @@
</headers> </headers>
<!-- <video class="videoBox" id="myVideo" :custom-cache="false" :src="url" controls autoplay></video> --> <!-- <video class="videoBox" id="myVideo" :custom-cache="false" :src="url" controls autoplay></video> -->
<!-- 外网IP地址访问视频监控 --> <!-- 外网IP地址访问视频监控 -->
<video class="videoBox" id="myVideo" :custom-cache="false" :src="'rtsp://42.180.188.17:'+url.substring(20)" controls autoplay></video> <video class="videoBox" id="myVideo" :custom-cache="false" :src="playUrlFilter" controls autoplay></video>
<view class="videoName"> <view class="videoName">
{{videoInfo.videoName}} {{videoInfo.videoName}}
<button v-if="videoInfo.videoType==3" type="primary" class="changeBtn btn" @click="changeStreamFn">{{streamType==1?'切换到主码流':'切换到子码流'}}</button> <button v-if="videoInfo.videoType==3" type="primary" class="changeBtn btn" @click="changeStreamFn">{{streamType==1?'切换到主码流':'切换到子码流'}}</button>
@ -41,6 +41,7 @@
url:'',//rtsp://admin:jxj12345@192.168.0.64:554/h264/ch1/main/av_stream url:'',//rtsp://admin:jxj12345@192.168.0.64:554/h264/ch1/main/av_stream
videoInfo:{videoName:'',videoType:null}, videoInfo:{videoName:'',videoType:null},
streamType: 1, //1 2 streamType: 1, //1 2
videoResponseInfo: {}
}; };
}, },
onLoad(options) { onLoad(options) {
@ -53,11 +54,16 @@
this.getPlayUrl() this.getPlayUrl()
} }
}, },
computed: {
playUrlFilter(){
return this.url?'rtsp://42.180.188.17:'+this.url.substring(20):""
}
},
methods:{ methods:{
// //
toBackList(){ toBackList(){
uni.navigateTo({ uni.navigateTo({
url: './playBackList' url: './playBackList?obj=' + JSON.stringify(this.videoResponseInfo)
}) })
}, },
changeStreamFn(){ changeStreamFn(){
@ -88,6 +94,12 @@
that.url=res.result.videoInfo.url that.url=res.result.videoInfo.url
break; break;
} }
that.videoResponseInfo = {...res.result.projectVideoConfig,...res.result.videoInfo};
for(let i in that.videoResponseInfo){
if(!that.videoResponseInfo[i]){
delete that.videoResponseInfo[i]
}
}
} }
}) })
}, },