提交 a74fc94f 编写于 作者: lyf's avatar lyf

Merge branch 'develop' into feat/yf

......@@ -38,7 +38,7 @@
</div>
<div class="viedo-btn-wrap" :id="rtc.viewslist[index] ? rtc.viewslist[index].id : ''">
<el-button class="call-btn"
:class="{calling1: item.role == 1 && doctorTrtcEntryStatus== 3, calling2: item.role == 2 && userTrtcEntryStatus== 3}"
:class="{calling1: item.role == 1 && doctorTrtcEntryStatus != 2, calling2: item.role == 2 && userTrtcEntryStatus != 2}"
@click="drivingCall(item)">
{{ item.role == 1 ? showText(doctorTrtcEntryStatus) : showText(userTrtcEntryStatus)}}
</el-button>
......@@ -128,7 +128,7 @@ export default {
memberList: [],
tid: "", // 群id
diagnoseLogId: "", //问诊id
isMuted: false,
isMuted: true,
liveInfoSave: {},
userTrtcEntryStatus:'',
doctorTrtcEntryStatus:''
......@@ -181,18 +181,18 @@ export default {
},
// 主动呼叫
drivingCall(data) {
if(data.role == 1 && this.doctorTrtcEntryStatus == 3){
if(data.role == 1 && this.doctorTrtcEntryStatus != 2){
return false;
}
if(data.role == 2 && this.userTrtcEntryStatus == 3){
if(data.role == 2 && this.userTrtcEntryStatus != 2){
return false;
}
console.log('--this.roomId', data, this.roomId);
let url = `/im/team/call/direct/`;
let params = {
imAccId: data.accId,
imTeamId: this.currentChat.tid,
liveRoomId: this.roomId
// imTeamId: this.currentChat.tid,
// liveRoomId: this.roomId
};
this.POST(url, params).then((res) => {
if (res.code === "000000") {
......@@ -202,7 +202,6 @@ export default {
message: '呼叫成功',
type: "success",
});
console.log('--data', data);
if(data.role == 1){
this.doctorTrtcEntryStatus = 3;
}
......@@ -224,6 +223,7 @@ export default {
.then((res) => {
if (res.code == "000000") {
let { liveInfo, memberList } = res.data;
console.log('---liveInfo', liveInfo, memberList);
if (liveInfo) {
this.startTime = liveInfo.startTimestamp;
this.endTime = liveInfo.endTimestamp;
......@@ -316,6 +316,7 @@ export default {
.then(() => {
Promise.all([this.rtc.join()]).then((res) => {
this.ispending();
this.muteLocalAudio();
let t = setTimeout(() => {
closeLoading(this);
this.muteLocalAudio();
......@@ -401,8 +402,15 @@ export default {
if (item.liveUserId == id) {
item.status = 2;
this.setTime(item.role);
if(item.role == 1){
this.doctorTrtcEntryStatus = 1;
}
if(item.role == 2){
this.userTrtcEntryStatus = 1;
}
}
});
console.log('---this.addNewMember', this.memberList, id);
},
// 用户下线
removeMember(id) {
......@@ -411,6 +419,7 @@ export default {
item.status = 3;
}
});
console.log('---this.removeMember', this.memberList, id);
},
//设置进行时长 1表示为问诊 2为接诊 3为问诊开始 4为问诊结束
setTime(flag) {
......
......@@ -76,7 +76,7 @@ export default {
};
</script>
<style lang="scss" scoped>
<style lang="scss">
.consultationlist {
padding: 25px;
width: 100%;
......
......@@ -136,7 +136,7 @@ export default {
}
</script>
<style lang="scss" scoped>
<style lang="scss">
.diagnoseAdvice-wrap{
position: absolute;
top: 125px;
......
......@@ -16,8 +16,8 @@
</div>
</div>
<div class="right">
<div class="right-status" :class="{ grey: 'returnStatus ==', org: '' }">
{{ returnStatusText }}
<div class="right-status" :class="{grey: item.returnStatus >= 5, org: item.returnStatus == 1}">
{{returnStatusText}}
</div>
<!-- <div class="right-time">-->
<!-- 已经问诊-->
......@@ -188,15 +188,15 @@ export default {
returnStatusText() {
switch (this.item.returnStatus) {
case 1:
return "待处理";
return '待处理'
case 2:
return "问诊进行中";
return '问诊进行中'
case 3:
return "未开始";
return '未开始'
case 4:
return "问诊已结束";
return '问诊已完成'
case 5:
return "已取消";
return '已取消'
default:
return "暂无";
}
......
......@@ -80,6 +80,14 @@ export default {
style: `float:right;margin-top:${30}px;`,
on: {
click: function () {
if(state.showChat){
_VM.$message({
message: '不可同时进入多个诊室,请先退出已进入的诊室,再试。',
type: "warning",
duration:1000
});
return false;
}
store.dispatch('gotoInquiry', payload);
cn.close();
},
......
......@@ -54,7 +54,7 @@ class RtcClient {
userId: this.userId_,
mirror: true
});
// this.startRTC()
this.startRTC()
} catch (e) {
console.error('加入房间失败 ' + e);
this.vueInstance.reloadfn()
......@@ -198,6 +198,8 @@ class RtcClient {
//对于本地流,调用该方法会触发远端 Client.on('unmute-audio') 事件。
//音频轨道默认是开启的,若你调用 muteAudio() 后可用该方法重新启用音频。
unmuteLocalAudio() {
const a = this.localStream_.getAudioTrack();
console.log('---a',a);
this.localStream_.unmuteAudio();
}
......
......@@ -31,10 +31,8 @@
</div>
</template>
<script>
import { mapGetters } from "vuex";
import { setTimeout } from "timers";
import { isNotEmptyUtils } from "../../utils/utils";
import { getInnerLoginUrl } from "../../utils";
const BUILD_ENV = process.env.BUILD_ENV;
let vm = null;
export default {
props: {
......@@ -82,7 +80,8 @@ export default {
isSuper:false,
userID: userId
};
this.$store.dispatch( 'socket/initSocket',{url: 'https://dev-sockets.yunqueyi.com',userId: userId})
const u = this.getSocketUrl(BUILD_ENV);
this.$store.dispatch( 'socket/initSocket',{url: u,userId: userId})
vueMenuDtos.map( item => {
if(item.index.indexOf('administrators') > -1){
// 超级管理员
......@@ -126,6 +125,27 @@ export default {
if (navList.indexOf(path) == -1) {
this.$router.push(`/${navList[0]}`);
}
},
getSocketUrl (env){
let url = '';
switch(env) {
case 'development':
url ='https://dev-sockets.yunqueyi.com';
break;
case 'test':
url ='https://test1-sockets.yunqueyi.com';
break;
case 'uat':
url ='https://uat-sso-sockets.yunqueyi.com';
break;
case 'pro':
url ='https://sso-sockets.yunqueyi.com';
break;
default:
url ='https://dev-sockets.yunqueyi.com';
break;
}
return url
}
}
};
......
Markdown 格式
0% or
您添加了 0 到此讨论。请谨慎行事。
先完成此消息的编辑!
想要评论请 注册