提交 3bc49e51 编写于 作者: 张磊's avatar 张磊

save

上级 5da3c999
...@@ -84,11 +84,9 @@ export default { ...@@ -84,11 +84,9 @@ export default {
watch: { watch: {
currentChat(newVal, oldVal) { currentChat(newVal, oldVal) {
if(newVal !== oldVal && newVal.imTeamId){ if(newVal !== oldVal && newVal.imTeamId){
const {imTeamId, diagnoseLogId, doctorTrtcEntryStatus, userTrtcEntryStatus} = this.currentChat; const {imTeamId, diagnoseLogId,} = this.currentChat;
this.tid = imTeamId; this.tid = imTeamId;
this.diagnoseLogId = diagnoseLogId; this.diagnoseLogId = diagnoseLogId;
// this.doctorTrtcEntryStatus = doctorTrtcEntryStatus;
// this.userTrtcEntryStatus = userTrtcEntryStatus;
this.init(); this.init();
} }
} }
...@@ -316,7 +314,6 @@ export default { ...@@ -316,7 +314,6 @@ export default {
.then(() => { .then(() => {
Promise.all([this.rtc.join()]).then((res) => { Promise.all([this.rtc.join()]).then((res) => {
this.ispending(); this.ispending();
this.muteLocalAudio();
let t = setTimeout(() => { let t = setTimeout(() => {
closeLoading(this); closeLoading(this);
this.muteLocalAudio(); this.muteLocalAudio();
......
...@@ -198,8 +198,6 @@ class RtcClient { ...@@ -198,8 +198,6 @@ class RtcClient {
//对于本地流,调用该方法会触发远端 Client.on('unmute-audio') 事件。 //对于本地流,调用该方法会触发远端 Client.on('unmute-audio') 事件。
//音频轨道默认是开启的,若你调用 muteAudio() 后可用该方法重新启用音频。 //音频轨道默认是开启的,若你调用 muteAudio() 后可用该方法重新启用音频。
unmuteLocalAudio() { unmuteLocalAudio() {
const a = this.localStream_.getAudioTrack();
console.log('---a',a);
this.localStream_.unmuteAudio(); this.localStream_.unmuteAudio();
} }
...@@ -251,7 +249,7 @@ class RtcClient { ...@@ -251,7 +249,7 @@ class RtcClient {
this.client_.on('peer-leave', evt => { this.client_.on('peer-leave', evt => {
const userId = evt.userId; const userId = evt.userId;
console.log('有远程同伴离开房间:' + userId); console.log('有远程同伴离开房间:' + userId);
this.remove(userId) this.removeUserList(userId)
}); });
...@@ -345,7 +343,7 @@ class RtcClient { ...@@ -345,7 +343,7 @@ class RtcClient {
this.remoteStreams_ = this.remoteStreams_.filter(stream => { this.remoteStreams_ = this.remoteStreams_.filter(stream => {
return stream.getId() !== id; return stream.getId() !== id;
}); });
this.remove(uid) this.removeUserList(uid)
}); });
// 流更新 // 流更新
...@@ -401,7 +399,7 @@ class RtcClient { ...@@ -401,7 +399,7 @@ class RtcClient {
} }
// 移除视频数组 // 移除视频数组
remove(userId) { removeUserList(userId) {
for(let i = 0; i < this.viewslist.length; i++) { for(let i = 0; i < this.viewslist.length; i++) {
if (this.viewslist[i] && this.viewslist[i].userId == userId) { if (this.viewslist[i] && this.viewslist[i].userId == userId) {
this.viewslist[i] = null this.viewslist[i] = null
......
Markdown 格式
0% or
您添加了 0 到此讨论。请谨慎行事。
先完成此消息的编辑!
想要评论请 注册