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

Merge branch 'feat/zl' into 'develop'

im chat ui

See merge request !37
...@@ -46,7 +46,7 @@ export default { ...@@ -46,7 +46,7 @@ export default {
userName: "", userName: "",
authList: [], authList: [],
systemType: 0, systemType: 0,
showChat:false showChat:true
}; };
}, },
computed: { computed: {
......
...@@ -2,65 +2,59 @@ ...@@ -2,65 +2,59 @@
position: absolute; position: absolute;
top: 20px; top: 20px;
right: 20px; right: 20px;
//min-height: 900px;
min-width: 700px;
z-index: 1000; z-index: 1000;
border: 1px solid #8fa4ac; width: 640px;
height: 733px;
background: #ffffff;
box-shadow: 10px 10px 50px 0px #D9D9D9;
overflow: hidden;
border-radius: 18px;
.component-content { .component-content {
display: flex;
flex-direction: row;
// min-width: 1200px;
background: none !important;
font-size: 14px;
height: 100%;
.center { .center {
//margin-left: 10%; //margin-left: 10%;
//margin-right: 10%; //margin-right: 10%;
flex: 1; flex: 1;
background: #fff; background: #fff;
.c-header { .c-header {
padding: 0 25px; //height: 40px;
height: 56px; padding: 15px 24px;
display: flex; .header-line {
flex-direction: row;
justify-content: space-between;
align-items: center;
border-bottom: 2px solid #f5f5f5;
& > .c-header-l {
flex: 1;
display: flex; display: flex;
flex-direction: row; flex-direction: row;
justify-content: space-between;
align-items: center; align-items: center;
& > img { }
display: inline-block; .c-header-l {
width: 24px; color: #063948;
height: 24px; .num{
border-radius: 12px; font-size: 28px;
margin-right: 8px;
}
& > .name {
margin-right: 25px;
color: #333333;
} }
& > .time-tip { .dep{
font-size: 12px; font-size: 20px;
color: #999999;
} }
} }
.close-btn { .c-header-edit{
width: 100px; display: flex;
color: #c7c8c9; min-width: 111px;
cursor: pointer; justify-content: space-around;
.edit-img{
width: 24px;
height: 24px;
img{
width: 100%;
height: 100%;
}
}
} }
} }
.msg-content { .msg-content {
// width: 100%; background: #F0F2F5;
// height: 650px;
word-break: break-all; word-break: break-all;
overflow: scroll; overflow: scroll;
display: flex; display: flex;
flex-direction: column; flex-direction: column;
margin: 10px 20px; margin-top: 10px;
.msg-item { .msg-item {
display: flex; display: flex;
flex-direction: row; flex-direction: row;
......
...@@ -6,13 +6,28 @@ ...@@ -6,13 +6,28 @@
v-loadmore="getOldMSGHistory" v-loadmore="getOldMSGHistory"
> >
<section class="c-header"> <section class="c-header">
<div class="c-header-l"> <div class="header-line">
<img :src="doctorImg" alt /> <div class="c-header-l">
<span class="name">{{doctorName}}医生的问诊群聊</span> <span class="num">3519</span>
<span class="dep">&nbsp;内科</span>
</div>
<div class="c-header-edit">
<span class="edit-img">
<img src="../../assets/image/IM/im_close.png" alt />
</span>
<span class="edit-img">
<img src="../../assets/image/IM/im_close2.png" alt />
</span>
<span class="edit-img">
<img src="../../assets/image/IM/im_small.png" alt />
</span>
</div>
</div>
<div class="header-line">
</div> </div>
</section> </section>
<p class="refreshText"></p> <diagnosis-Live :doctorImg="doctorImg"></diagnosis-Live>
<diagnosis-Live></diagnosis-Live>
<section id="msgContentId" class="msg-content scroll-box"> <section id="msgContentId" class="msg-content scroll-box">
<article <article
v-for="(item, index) in messageList" v-for="(item, index) in messageList"
...@@ -187,7 +202,7 @@ ...@@ -187,7 +202,7 @@
import BreadCrumb from "@/components/breadcrumb.vue"; import BreadCrumb from "@/components/breadcrumb.vue";
import diagnosisLive from "./diagnosis-live"; import diagnosisLive from "./diagnosis-live";
import { doUpload, getFilePath } from "@/utils/qiniu-util"; import { doUpload, getFilePath } from "@/utils/qiniu-util";
import { openLoading, closeLoading, betaHandle, bindDragHeader } from "@/utils/utils"; import { openLoading, closeLoading, betaHandle } from "@/utils/utils";
import { getPicaKFAccid, getPhomeDemain } from "@/utils"; import { getPicaKFAccid, getPhomeDemain } from "@/utils";
const CONTAINER_HEIGHT = 700; const CONTAINER_HEIGHT = 700;
let forwardMsgIntervalId = null, let forwardMsgIntervalId = null,
...@@ -309,7 +324,7 @@ export default { ...@@ -309,7 +324,7 @@ export default {
this.$nextTick(() => { this.$nextTick(() => {
_this.containerHeight = document.body.clientHeight - 80; _this.containerHeight = document.body.clientHeight - 80;
// _this.getElmByID("screenSet").style.height = _this.containerHeight - 76 + "px"; // _this.getElmByID("screenSet").style.height = _this.containerHeight - 76 + "px";
_this.getElmByID("msgContentId").style.height = _this.containerHeight - 211 + "px"; _this.getElmByID("msgContentId").style.height = "400px";
}); });
}, },
......
...@@ -2,23 +2,19 @@ ...@@ -2,23 +2,19 @@
<div class="livebox"> <div class="livebox">
<div class="top"> <div class="top">
<div class="top-left"> <div class="top-left">
<h1 class="title">{{ title }}</h1> <div class="time-message ">
<div class="time-message"> <p class="msg-img">
<img :src="im_text" alt />
</p>
<span>{{ title }}</span>
</div>
<div class="time-message ml10">
<p class="msg-img"> <img :src="im_time" alt /></p>
<p>设定时长: {{ time }}分钟</p> <p>设定时长: {{ time }}分钟</p>
<p v-if="startTime && endTime">总时长: {{ useTime }}</p> <p v-if="startTime && endTime">总时长: {{ useTime }}</p>
<p v-if="startTime && endTime">剩余时长: {{ loseTime }}</p> <p v-if="startTime && endTime">剩余时长: {{ loseTime }}</p>
</div> </div>
</div> </div>
<div class="top-right">
<img
:src="isMicOn ? voiceSmallImg : voiceCloseImg"
alt=""
srcset=""
class="icon"
@click="taggleM"
/>
<div class="close" @click="overFn">结束会话</div>
</div>
</div> </div>
<div class="main"> <div class="main">
<div <div
...@@ -27,74 +23,30 @@ ...@@ -27,74 +23,30 @@
:key="index" :key="index"
> >
<div class="text"> <div class="text">
<p>{{ item.name }}</p> <div class="text-left">
<p>{{ item.role == 1 ? "问诊医生" : "接诊医生" }}:</p> <img :src="doctorImg" alt />
</div>
<div class="viedo">
<div
:id="rtc.viewslist[index].id"
v-if="rtc && rtc.viewslist[index]"
></div>
<!-- 用户声音icon -->
<img
:src="
rtc && rtc.viewslist[index] && rtc.viewslist[index].vioce
? voiceSmallImg
: voiceCloseImg
"
alt=""
srcset=""
class="user-icon"
v-if="item.status == 2"
/>
<img
:src="setImg(item.status)"
alt=""
srcset=""
class="video-icon"
v-else
/>
<div
class="mask"
v-if="rtc && rtc.viewslist[index] && rtc.viewslist[index].mask"
>
<img
:src="type == 1 ? voiceImg : noCameraImg"
alt=""
:class="{ vocie: type == 1 }"
/>
</div> </div>
</div> <div class="text-right">
<div class="time"> <p>
<!-- //等待连接还是已经下麦 1为等待 2为进行中 3为下麦 --> <span class="text-name">{{ item.name }}</span>
<div class="time-content"> <span class="text-dep">{{ item.role == 1 ? "问诊医生" : "接诊医生" }}</span>
<el-button </p>
class="call-btn" <p class="text-num">123123123</p>
size="mini"
:disabled="item.status == 2 && item.timeleft == 0"
type="primary"
:loading="item.timeleft > 0"
@click="drivingCall(item)"
>
<span v-if="item.timeleft == 0"
>呼叫{{ item.role == 1 ? "问诊医生" : "接诊医生" }}</span
>
<time-left
@setItem="setItem($event, item)"
v-else
:timeleft="item.timeleft"
></time-left>
</el-button>
<span>
{{ showText(item.status, item.role, item) }}
</span>
</div> </div>
</div> </div>
<div class="viedo">
<el-button class="call-btn"> 已接入</el-button>
</div>
</div>
<div class="vedio-man">
<p class="man-img">
<img :src="im_man1" alt />
</p>
<p class="man-txt">
已接入
</p>
</div> </div>
</div> </div>
<div class="out" @click="leave">退出</div>
<alert ref="alert"></alert> <alert ref="alert"></alert>
</div> </div>
</template> </template>
...@@ -115,6 +67,12 @@ export default { ...@@ -115,6 +67,12 @@ export default {
alert, alert,
timeLeft, timeLeft,
}, },
props: {
doctorImg: {
type: String | Number,
default: ''
}
},
data() { data() {
return { return {
closeCallImg: require("../../assets/image/live/close-call.png"), closeCallImg: require("../../assets/image/live/close-call.png"),
...@@ -123,6 +81,11 @@ export default { ...@@ -123,6 +81,11 @@ export default {
voiceImg: require("../../assets/image/live/voice.png"), voiceImg: require("../../assets/image/live/voice.png"),
waitingCallImg: require("../../assets/image/live/waiting-call.png"), waitingCallImg: require("../../assets/image/live/waiting-call.png"),
noCameraImg: require("../../assets/image/live/no-camera.png"), noCameraImg: require("../../assets/image/live/no-camera.png"),
im_text: require("../../assets/image/IM/im_text.png"),
im_video: require("../../assets/image/IM/im_video.png"),
im_time: require("../../assets/image/IM/im_time.png"),
im_man1: require("../../assets/image/IM/im_man1.png"),
im_man2: require("../../assets/image/IM/im_man2.png"),
roleAnchor: "anchor", // 主播 roleAnchor: "anchor", // 主播
rtc: null, rtc: null,
roomId: "", roomId: "",
...@@ -607,40 +570,35 @@ export default { ...@@ -607,40 +570,35 @@ export default {
.livebox { .livebox {
display: flex; display: flex;
flex-direction: column; flex-direction: column;
//position: absolute; background: #ffffff;
//top: 0; padding: 15px 24px;
//left: 0; padding-top: 0px;
//right: 0;
//bottom: 0;
background: #000000;
.top { .top {
display: flex;
margin-top: 5%;
justify-content: space-between;
.top-left { .top-left {
margin-left: 24px; text-align: left;
.title { display: flex;
width: 72px;
height: 22px;
font-size: 18px;
font-family: PingFangSC-Semibold, PingFang SC;
font-weight: 700;
color: #ffffff;
line-height: 22px;
}
.time-message { .time-message {
margin-top: 20px;
display: flex; display: flex;
height: 20px; height: 24px;
line-height: 24px;
background: #F0F2F5;
border-radius: 23px;
color: #6A7990;
font-size: 14px; font-size: 14px;
font-family: PingFangSC-Regular, PingFang SC; padding: 0px 15px;
font-weight: 400; .msg-img{
color: #ffffff; width: 12px;
line-height: 20px; height: 12px;
p { margin-right: 10px;
margin-right: 20px; img{
width: 100%;
height: 100%;
}
} }
} }
.ml10{
margin-left: 10px;
}
} }
.top-right { .top-right {
margin: 15px 25px 0 0; margin: 15px 25px 0 0;
...@@ -669,24 +627,46 @@ export default { ...@@ -669,24 +627,46 @@ export default {
} }
} }
.main { .main {
margin-top: 24px; margin-top: 25px;
display: flex; display: flex;
flex: 1; flex: 1;
.viedo-wrapper { .viedo-wrapper {
display: flex; width: 224px;
width: 49%; height: 120px;
height: 50vh; background: #F0F2F5;
background: #2d2d2d; border-radius: 18px;
&:first-of-type { padding: 15px;
margin-right: 2%; margin-right: 2%;
}
.text { .text {
display: flex; display: flex;
flex-direction: column-reverse; .text-left{
width: 112px; width: 36px;
margin-left: 24px; height: 36px;
color: #fff; background: #DDDDDD;
padding-bottom: 20px; border-radius: 36px;
img {
width: 100%;
height: 100%;
}
}
.text-right {
margin-left: 5px;
text-align: left;
.text-name{
font-size: 18px;
color: #063948;
font-weight: bold;
}
.text-dep{
margin-left: 5px;
font-size: 14px;
color: #063948;
}
.text-num{
font-size: 14px;
color: #6A7990;
}
}
} }
.time { .time {
display: flex; display: flex;
...@@ -712,53 +692,39 @@ export default { ...@@ -712,53 +692,39 @@ export default {
} }
} }
.viedo { .viedo {
flex: 1; .call-btn{
display: flex; width: 173px;
justify-content: center; height: 38px;
align-items: center; background: #449284;
position: relative; border-radius: 23px;
.user-icon { color: #ffffff;
position: absolute; margin-top: 15px;
right: 0; border: none;
bottom: 20px;
display: block;
width: 32px;
height: 32px;
z-index: 100;
} }
& > div { }
height: 100%; }
.vedio-man{
width: 120px;
height: 120px;
background: #F0F2F5;
border-radius: 18px;
padding: 9px;
.man-img{
width: 61px;
height: 61px;
border-radius: 61px;
background: #449284;
text-align: center;
margin: 0 auto;
img {
width: 100%; width: 100%;
video {
width: 100%;
height: 100%;
}
}
.video-icon {
width: 96px;
height: 96px;
}
.mask {
position: absolute;
top: 0;
left: 0;
right: 0;
bottom: 0;
background: #2d2d2d;
display: flex;
justify-content: center;
align-items: center;
img {
display: block;
width: 93px;
height: 125px;
}
.vocie {
width: 93px;
height: 93px;
}
} }
} }
.man-txt{
margin-top: 18px;
color: #449284;
font-size: 14px;
}
} }
} }
......
Markdown 格式
0% or
您添加了 0 到此讨论。请谨慎行事。
先完成此消息的编辑!
想要评论请 注册