From 3ef643d658a647651f80c08db7c15f66734cbab1 Mon Sep 17 00:00:00 2001
From: xiaoQQya <xiaoQQya@126.com>
Date: 星期三, 22 三月 2023 10:36:06 +0800
Subject: [PATCH] fix(snap): 修复 rtsp 端口为空时使用 mp4 协议截图失败的问题
---
web_src/src/components/dialog/MediaServerEdit.vue | 10 ++++++----
1 files changed, 6 insertions(+), 4 deletions(-)
diff --git a/web_src/src/components/dialog/MediaServerEdit.vue b/web_src/src/components/dialog/MediaServerEdit.vue
index edb4ff6..15923c1 100644
--- a/web_src/src/components/dialog/MediaServerEdit.vue
+++ b/web_src/src/components/dialog/MediaServerEdit.vue
@@ -78,7 +78,7 @@
<el-switch v-model="mediaServerForm.autoConfig" :disabled="mediaServerForm.defaultServer"></el-switch>
</el-form-item>
<el-form-item label="鏀舵祦绔彛妯″紡" >
- <el-switch active-text="澶氱鍙�" inactive-text="鍗曠鍙�" v-model="mediaServerForm.rtpEnable" :disabled="mediaServerForm.defaultServer"></el-switch>
+ <el-switch active-text="澶氱鍙�" inactive-text="鍗曠鍙�" @change="portRangeChange" v-model="mediaServerForm.rtpEnable" :disabled="mediaServerForm.defaultServer"></el-switch>
</el-form-item>
<el-form-item v-if="!mediaServerForm.rtpEnable" label="鏀舵祦绔彛" prop="rtpProxyPort">
@@ -335,7 +335,7 @@
var that = this;
await that.$axios({
method: 'get',
- url:`./api/platform/exit/${deviceGbId}`
+ url:`/api/platform/exit/${deviceGbId}`
}).then(function (res) {
result = res.data;
}).catch(function (error) {
@@ -349,8 +349,10 @@
}
},
portRangeChange: function() {
- this.mediaServerForm.rtpPortRange = this.rtpPortRange1 + "," + this.rtpPortRange2
- console.log(this.mediaServerForm.rtpPortRange)
+ if (this.mediaServerForm.rtpEnable) {
+ this.mediaServerForm.rtpPortRange = this.rtpPortRange1 + "," + this.rtpPortRange2
+ console.log(this.mediaServerForm.rtpPortRange)
+ }
}
},
};
--
Gitblit v1.8.0