develop
commit
ff8b4998fa
|
|
@ -1,3 +1,3 @@
|
||||||
ENV = 'development'
|
ENV = 'development'
|
||||||
|
|
||||||
VUE_APP_BASE_API = 'https://lcny.sk797.cn'
|
VUE_APP_BASE_API = 'https://lcny-api.peidikeji.cn'
|
||||||
|
|
@ -1,2 +1,2 @@
|
||||||
<!DOCTYPE html><html lang="zh-CN"><head><meta charset="utf-8"><meta http-equiv="X-UA-Compatible" content="IE=edge"><title></title><script>var coverSupport = 'CSS' in window && typeof CSS.supports === 'function' && (CSS.supports('top: env(a)') || CSS.supports('top: constant(a)'))
|
<!DOCTYPE html><html lang="zh-CN"><head><meta charset="utf-8"><meta http-equiv="X-UA-Compatible" content="IE=edge"><title></title><script>var coverSupport = 'CSS' in window && typeof CSS.supports === 'function' && (CSS.supports('top: env(a)') || CSS.supports('top: constant(a)'))
|
||||||
document.write('<meta name="viewport" content="width=device-width, user-scalable=no, initial-scale=1.0, maximum-scale=1.0, minimum-scale=1.0' + (coverSupport ? ', viewport-fit=cover' : '') + '" />')</script><link rel="stylesheet" href="https://lcny.sk797.cn/h5/static/index.97465e7b.css"></head><body><noscript><strong>Please enable JavaScript to continue.</strong></noscript><div id="app"></div><script src="https://lcny.sk797.cn/h5/static/js/chunk-vendors.959091ef.js"></script><script src="https://lcny.sk797.cn/h5/static/js/index.987265b5.js"></script></body></html>
|
document.write('<meta name="viewport" content="width=device-width, user-scalable=no, initial-scale=1.0, maximum-scale=1.0, minimum-scale=1.0' + (coverSupport ? ', viewport-fit=cover' : '') + '" />')</script><link rel="stylesheet" href="https://lcny.sk797.cn/h5/static/index.97465e7b.css"></head><body><noscript><strong>Please enable JavaScript to continue.</strong></noscript><div id="app"></div><script src="https://lcny.sk797.cn/h5/static/js/chunk-vendors.959091ef.js"></script><script src="https://lcny.sk797.cn/h5/static/js/index.02b5f60d.js"></script></body></html>
|
||||||
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
|
|
@ -37,11 +37,12 @@ http.interceptors.response.use((response) => { /* 请求之后拦截器*/
|
||||||
const { code } = response.data
|
const { code } = response.data
|
||||||
if (code != 200) {
|
if (code != 200) {
|
||||||
if (code == 4024) {
|
if (code == 4024) {
|
||||||
|
|
||||||
toast(response.data.msg)
|
toast(response.data.msg)
|
||||||
} else if (code == 401) {
|
} else if (code == 401) {
|
||||||
toast('请关闭,重新进入')
|
toast('请关闭,重新进入')
|
||||||
} else {
|
} else {
|
||||||
|
toast(response.data.msg ?? response.data.message)
|
||||||
}
|
}
|
||||||
return Promise.reject(response)
|
return Promise.reject(response)
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -108,7 +108,7 @@
|
||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
</u-form-item>
|
</u-form-item>
|
||||||
<u-form-item label="项目" label-width="140">
|
<u-form-item label="项目" label-width="140" :required='true'>
|
||||||
<view class="input_box">
|
<view class="input_box">
|
||||||
<view class="u-select-list" @click="selectFn4()">
|
<view class="u-select-list" @click="selectFn4()">
|
||||||
<view class="value u-line-2"
|
<view class="value u-line-2"
|
||||||
|
|
@ -127,32 +127,32 @@
|
||||||
</u-form-item>
|
</u-form-item>
|
||||||
<!-- 监控设备字段 -->
|
<!-- 监控设备字段 -->
|
||||||
<template v-if="setInfo.type==1">
|
<template v-if="setInfo.type==1">
|
||||||
<u-form-item label="设备IP" label-width="140" :required='true'>
|
<u-form-item label="设备IP" label-width="140" :required='false'>
|
||||||
<view class="input_box">
|
<view class="input_box">
|
||||||
<u-input v-model="extendConf.ip" type="text"/>
|
<u-input v-model="extendConf.ip" type="text"/>
|
||||||
</view>
|
</view>
|
||||||
</u-form-item>
|
</u-form-item>
|
||||||
<u-form-item label="设备端口" label-width="140" :required='true'>
|
<u-form-item label="设备端口" label-width="140" :required='false'>
|
||||||
<view class="input_box">
|
<view class="input_box">
|
||||||
<u-input v-model="extendConf.port" type="text"/>
|
<u-input v-model="extendConf.port" type="text"/>
|
||||||
</view>
|
</view>
|
||||||
</u-form-item>
|
</u-form-item>
|
||||||
<u-form-item label="RTSP地址" label-width="140" :required='true'>
|
<u-form-item label="RTSP地址" label-width="140" :required='false'>
|
||||||
<view class="input_box">
|
<view class="input_box">
|
||||||
<u-input v-model="extendConf.rtsp_url" type="text"/>
|
<u-input v-model="extendConf.rtsp_url" type="text"/>
|
||||||
</view>
|
</view>
|
||||||
</u-form-item>
|
</u-form-item>
|
||||||
<u-form-item label="设备登录名" label-width="160" :required='true'>
|
<u-form-item label="设备登录名" label-width="160" :required='false'>
|
||||||
<view class="input_box">
|
<view class="input_box">
|
||||||
<u-input v-model="extendConf.username" type="text"/>
|
<u-input v-model="extendConf.username" type="text"/>
|
||||||
</view>
|
</view>
|
||||||
</u-form-item>
|
</u-form-item>
|
||||||
<u-form-item label="设备登录密码" label-width="180" :required='true'>
|
<u-form-item label="设备登录密码" label-width="180" :required='false'>
|
||||||
<view class="input_box">
|
<view class="input_box">
|
||||||
<u-input v-model="extendConf.password" type="password"/>
|
<u-input v-model="extendConf.password" type="password"/>
|
||||||
</view>
|
</view>
|
||||||
</u-form-item>
|
</u-form-item>
|
||||||
<u-form-item label="设备播放通道" label-width="180" :required='true'>
|
<u-form-item label="设备播放通道" label-width="180" :required='false'>
|
||||||
<view class="input_box">
|
<view class="input_box">
|
||||||
<u-input v-model="extendConf.passage" type="text"/>
|
<u-input v-model="extendConf.passage" type="text"/>
|
||||||
</view>
|
</view>
|
||||||
|
|
|
||||||
|
|
@ -135,7 +135,7 @@
|
||||||
</view>
|
</view>
|
||||||
<view class="content-box">
|
<view class="content-box">
|
||||||
<view class="video_ul" v-show="current == 0">
|
<view class="video_ul" v-show="current == 0">
|
||||||
<view class="video_li" v-for="(video, index) in videoList" :key="index">
|
<view class="video_li" v-for="(video, index) in videoList" :key="video.video_url+index">
|
||||||
<view class="video_cd">
|
<view class="video_cd">
|
||||||
<!-- #ifdef H5 -->
|
<!-- #ifdef H5 -->
|
||||||
<!-- {{ video.video_url }} -->
|
<!-- {{ video.video_url }} -->
|
||||||
|
|
@ -164,7 +164,7 @@
|
||||||
<view
|
<view
|
||||||
class="video_li"
|
class="video_li"
|
||||||
v-for="(video, index) in videoList2"
|
v-for="(video, index) in videoList2"
|
||||||
:key="index"
|
:key="video.video_url+index"
|
||||||
>
|
>
|
||||||
<view class="video_cd">
|
<view class="video_cd">
|
||||||
<!-- #ifdef H5 -->
|
<!-- #ifdef H5 -->
|
||||||
|
|
@ -381,6 +381,11 @@ export default {
|
||||||
console.log(data, 'queryWebsocketIp')
|
console.log(data, 'queryWebsocketIp')
|
||||||
if (data.code == 200) {
|
if (data.code == 200) {
|
||||||
this.websocket = data.data
|
this.websocket = data.data
|
||||||
|
let url = `${this.websocket.ssl?'wss':'ws'}://${this.websocket.host?this.websocket.host:this.websocket.ip+':'+this.websocket.port}`
|
||||||
|
this.websocket.url = url
|
||||||
|
// this.websocket.ip = 'lcny-rtsp.peidikeji.cn'
|
||||||
|
// console.log(this.websocket);
|
||||||
|
// this.websocket.id='lcny-rtsp.peidikeji.cn'
|
||||||
}
|
}
|
||||||
} catch (e) {
|
} catch (e) {
|
||||||
//TODO handle the exception
|
//TODO handle the exception
|
||||||
|
|
@ -423,10 +428,10 @@ export default {
|
||||||
let list = data.data
|
let list = data.data
|
||||||
for (let item of list) {
|
for (let item of list) {
|
||||||
let url = item.extends.rtsp_url
|
let url = item.extends.rtsp_url
|
||||||
let { ip, port } = this.websocket
|
let { ip, port ,url:uri} = this.websocket
|
||||||
|
// ip='lcny-rtsp.peidikeji.cn'
|
||||||
if (url) {
|
if (url) {
|
||||||
item.video_url = `ws://${ip}:${port}/rtsp?url=${window.btoa(
|
item.video_url = `${uri}/rtsp?url=${window.btoa(
|
||||||
url
|
url
|
||||||
)}`
|
)}`
|
||||||
}
|
}
|
||||||
|
|
@ -510,9 +515,7 @@ export default {
|
||||||
)
|
)
|
||||||
let p_url = `rtsp://${username}:${password}@${ip}:${port}/cam/playback?channel=${passage}&subtype=0`
|
let p_url = `rtsp://${username}:${password}@${ip}:${port}/cam/playback?channel=${passage}&subtype=0`
|
||||||
let rtsp_url = `${p_url}&starttime=${stime}&endtime=${etime}`
|
let rtsp_url = `${p_url}&starttime=${stime}&endtime=${etime}`
|
||||||
item.video_url = `ws://${this.websocket.ip}:${
|
item.video_url = `${this.websocket.url}/rtsp?url=${window.btoa(rtsp_url)}}`
|
||||||
this.websocket.port
|
|
||||||
}/rtsp?url=${window.btoa(rtsp_url)}}`
|
|
||||||
console.log(rtsp_url, item.video_url, '视频url')
|
console.log(rtsp_url, item.video_url, '视频url')
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue