From e0117a488256fdf042523f802ad6804cde6cd130 Mon Sep 17 00:00:00 2001 From: blue <825657193@qq.com> Date: Wed, 26 Jun 2024 22:37:50 +0800 Subject: [PATCH] =?UTF-8?q?fix=EF=BC=9Aweb=E7=AB=AF=E5=8D=95=E4=BA=BA?= =?UTF-8?q?=E9=80=9A=E8=AF=9Dbug?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- im-ui/src/api/rtcPrivateApi.js | 15 ++++++++++++--- im-ui/src/components/rtc/RtcGroupVideo.vue | 3 +++ 2 files changed, 15 insertions(+), 3 deletions(-) diff --git a/im-ui/src/api/rtcPrivateApi.js b/im-ui/src/api/rtcPrivateApi.js index 687ee65..82dddab 100644 --- a/im-ui/src/api/rtcPrivateApi.js +++ b/im-ui/src/api/rtcPrivateApi.js @@ -7,7 +7,10 @@ RtcPrivateApi.prototype.call = function(uid, mode, offer) { return http({ url: `/webrtc/private/call?uid=${uid}&mode=${mode}`, method: 'post', - data: JSON.stringify(offer) + data: JSON.stringify(offer), + headers: { + 'Content-Type': 'application/json; charset=utf-8' + } }) } @@ -15,7 +18,10 @@ RtcPrivateApi.prototype.accept = function(uid, answer) { return http({ url: `/webrtc/private/accept?uid=${uid}`, method: 'post', - data: JSON.stringify(answer) + data: JSON.stringify(answer), + headers: { + 'Content-Type': 'application/json; charset=utf-8' + } }) } @@ -52,7 +58,10 @@ RtcPrivateApi.prototype.sendCandidate = function(uid, candidate) { return http({ url: `/webrtc/private/candidate?uid=${uid}`, method: 'post', - data: JSON.stringify(candidate) + data: JSON.stringify(candidate), + headers: { + 'Content-Type': 'application/json; charset=utf-8' + } }); } diff --git a/im-ui/src/components/rtc/RtcGroupVideo.vue b/im-ui/src/components/rtc/RtcGroupVideo.vue index d5d028d..96abad3 100644 --- a/im-ui/src/components/rtc/RtcGroupVideo.vue +++ b/im-ui/src/components/rtc/RtcGroupVideo.vue @@ -29,6 +29,9 @@ methods: { open() { this.isShow = true; + }, + onRTCMessage(){ + //this.isShow = true; } } }