提交 ea0d8863 编写于 作者: guangjun.yang's avatar guangjun.yang

Merge branch 'dev-phase1-0111' of...

Merge branch 'dev-phase1-0111' of 192.168.110.53:com.pica.cloud.education.frontend/pica-admin-IM into dev-phase1-0111

* 'dev-phase1-0111' of 192.168.110.53:com.pica.cloud.education.frontend/pica-admin-IM:
  时间选择
  时间选择
  群发历史添加图片放大
  详情图片显示
......@@ -8,7 +8,7 @@
<div v-if="item.type == 0" class="text-content">
<div>{{item.info}}</div>
</div>
<div v-if="item.type == 1" class="img-content">
<div v-if="item.type == 1" class="img-content" v-viewer>
<img :src="item.url" />
</div>
<div v-if="item.type == 2" class="file-content">
......
......@@ -184,7 +184,7 @@ export default {
return document.getElementById(elmId);
},
// 获取详情数据以及下拉加载历史数据
getDeatailData(param) {
getDeatailData(param) { // 最新的时间在最后面
let url = '/im/msg/forward';
let req = {
doctorAccId: this.doctorAccId,
......@@ -197,9 +197,9 @@ export default {
this.POST(url, req).then((res) => {
if(res.code == '000000') {
let arr = [];
this.historyTime = res.data[res.data.length - 1].timestamp;
if(res.data.length > 0) {
this.hasForwardData = true;
this.historyTime = res.data[0].timestamp;
this.lastMsgTime = res.data[res.data.length - 1].timestamp;
arr = this.dataconcatHandle(res.data);
this.detailData.push(...arr);
......@@ -216,7 +216,7 @@ export default {
})
},
// 上翻查看最新消息
getHistoryData(param) {
getHistoryData(param) { // 最新的时间在最前面
let url = '/im/msg/history';
let req = {
doctorAccId: this.doctorAccId,
......@@ -231,7 +231,7 @@ export default {
let arr = [], sortArr = [];
if(res.data.length > 0) {
this.hasHistoryData = true;
this.historyTime = res.data[0].timestamp;
this.historyTime = res.data[res.data.length - 1].timestamp;
arr = this.dataconcatHandle(res.data.reverse());
this.detailData.unshift(...arr);
let el = this.getElmByID('scroll-set');
......@@ -262,7 +262,7 @@ export default {
}
}
this.$set(element, index, 'sessionFlag');
if(element.type == 'CUSTOM') {
if(element.type == 'CUSTOM' || element.type == 'PICTURE') {
element.content = JSON.parse(element.content);
}
});
......
Markdown 格式
0% or
您添加了 0 到此讨论。请谨慎行事。
先完成此消息的编辑!
想要评论请 注册