Commit c2d3580a by xinla

会话消息修改

1 parent fc06369a
...@@ -76,14 +76,11 @@ export default { ...@@ -76,14 +76,11 @@ export default {
</script> </script>
<template> <template>
<div> <div class="message">
<div v-if="message.msgType === 'text'" class="msgtypetext"> <template v-if="message.msgType === 'text'">
{{ content }} {{ content }}
</div> </template>
<div <template v-else-if="'image,emotion'.includes(message.msgType)">
v-else-if="'image,emotion'.includes(message.msgType)"
class="msgtypeimg"
>
<el-image <el-image
style="width: 100px; height: 100px" style="width: 100px; height: 100px"
:src="content" :src="content"
...@@ -91,7 +88,7 @@ export default { ...@@ -91,7 +88,7 @@ export default {
:preview-src-list="[content]" :preview-src-list="[content]"
> >
</el-image> </el-image>
</div> </template>
<a <a
v-else-if="'file'.includes(message.msgType)" v-else-if="'file'.includes(message.msgType)"
class="msgtypefile" class="msgtypefile"
...@@ -108,7 +105,7 @@ export default { ...@@ -108,7 +105,7 @@ export default {
> >
{{ content }} {{ content }}
</a> </a>
<div v-else-if="message.msgType === 'voice'" class="msgtypevoice"> <div v-else-if="message.msgType === 'voice'">
<i <i
class="el-icon-microphone" class="el-icon-microphone"
style=" font-size: 40px; color: #199ed8;" style=" font-size: 40px; color: #199ed8;"
...@@ -209,6 +206,25 @@ export default { ...@@ -209,6 +206,25 @@ export default {
</template> </template>
<style lang="scss" scoped> <style lang="scss" scoped>
.message {
position: relative;
padding: 10px;
line-height: 14px;
border-radius: 5px;
background: $blue;
color: #fff;
display: inline-block;
&::before {
content: '';
display: inline-block;
position: absolute;
left: -13px;
width: 0;
height: 0;
border: 7px solid transparent;
border-right-color: $blue;
}
}
.msgtypefile { .msgtypefile {
margin: 5px; margin: 5px;
width: 200px; width: 200px;
......
...@@ -4,7 +4,7 @@ ...@@ -4,7 +4,7 @@
<li v-for="(item, index) in allChat" :key="index"> <li v-for="(item, index) in allChat" :key="index">
<!-- <span v-if="item.fromInfo.name">{{item.fromInfo.name}}</span> --> <!-- <span v-if="item.fromInfo.name">{{item.fromInfo.name}}</span> -->
<div class="mb15"> <div class="mb15">
<span class="mr20">{{ item.fromId }}</span> <span class="mr20">{{ item.name }}</span>
<span <span
:style="{ color: item.action == 'send' ? '#199ed8' : '#999' }" :style="{ color: item.action == 'send' ? '#199ed8' : '#999' }"
>{{ item.msgTime }}</span >{{ item.msgTime }}</span
......
...@@ -67,9 +67,7 @@ ...@@ -67,9 +67,7 @@
<el-col :span="12"> <el-col :span="12">
<div class="hd_box"> <div class="hd_box">
<div class="hd_name"> <div class="hd_name">
<span v-if="chat.receiveWeCustomer"> <span v-if="chat"> 与{{ chat.name }}的聊天</span>
与{{ chat.receiveWeCustomer.name }}的聊天</span
>
<span class="fr hd_nameRi" @click="exportList()">下载会话</span> <span class="fr hd_nameRi" @click="exportList()">下载会话</span>
</div> </div>
</div> </div>
......
Markdown is supported
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!