From bc780133efdcf559a32ddc31d0d7a78c06ca9cee Mon Sep 17 00:00:00 2001 From: z_yu <1534695664@qq.com> Date: Wed, 24 Aug 2022 13:34:09 +0800 Subject: [PATCH] =?UTF-8?q?=E6=91=84=E5=83=8F=E5=A4=B4=E6=9C=8D=E5=8A=A1?= =?UTF-8?q?=E5=99=A8=E5=9C=B0=E5=9D=80?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .env.development | 2 +- .env.production | 2 +- src/views/storeManage/warehouse3D/module/video.vue | 7 ++++--- 3 files changed, 6 insertions(+), 5 deletions(-) diff --git a/.env.development b/.env.development index 338adc0..fe8e577 100644 --- a/.env.development +++ b/.env.development @@ -5,7 +5,7 @@ ENV = 'development' #内网服务地址 VUE_APP_BASE_API = 'http://192.168.99.207:7070' VUE_APP_WS_API = 'ws://192.168.99.207:7071' -CAMERA_APP_BASE_API = '192.168.99.207' +VUE_APP_CAMERA_API = '192.168.99.107' # 刘力-本地服地址 #VUE_APP_BASE_API = 'http://192.168.99.65:7070' diff --git a/.env.production b/.env.production index 21a47ec..bc79d02 100644 --- a/.env.production +++ b/.env.production @@ -5,4 +5,4 @@ ENV = 'production' VUE_APP_BASE_API = 'http://192.168.99.207:7070' # 如果接口是 http 形式, wss 需要改为 ws VUE_APP_WS_API = 'ws://192.168.99.207:7071' -CAMERA_APP_BASE_API = '192.168.99.207' +VUE_APP_CAMERA_API = '192.168.99.107' diff --git a/src/views/storeManage/warehouse3D/module/video.vue b/src/views/storeManage/warehouse3D/module/video.vue index dc0a49d..429c0e0 100644 --- a/src/views/storeManage/warehouse3D/module/video.vue +++ b/src/views/storeManage/warehouse3D/module/video.vue @@ -57,7 +57,8 @@ export default { // this.myVideo.pause() // $.post('http://127.0.0.1:3000/cameras/close/', { rtspUrl: $('#rtsp').val() }, function(result) { const data = { rtspUrl: this.rtspUrl } - const Uri = 'http://' + process.env.CAMERA_APP_BASE_API + ':3000/cameras/close/' + // console.log(process.env.VUE_APP_CAMERA_API) + const Uri = 'http://' + process.env.VUE_APP_CAMERA_API + ':3000/cameras/close/' axios.post(Uri, qs.stringify(data), { headers: { @@ -76,7 +77,7 @@ export default { }, play() { const data = { rtspUrl: this.rtspUrl, size: '1024*768' } - const Uri = 'http://' + process.env.CAMERA_APP_BASE_API + ':3000/cameras/' + const Uri = 'http://' + process.env.VUE_APP_CAMERA_API + ':3000/cameras/' axios.post(Uri, qs.stringify(data), { headers: { @@ -85,7 +86,7 @@ export default { } ).then(res => { // res.data.port - const url = 'ws://' + process.env.CAMERA_APP_BASE_API + ':' + res.data.port + const url = 'ws://' + process.env.VUE_APP_CAMERA_API + ':' + res.data.port // var canvas = document.getElementById('canvas') const opt = { contianer: this.$refs['canvas-wrap'],