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

解决bug等

上级 aee7c041
......@@ -367,9 +367,8 @@
}
p {
margin-top: 10px;
text-align: center;
font-size: 14px;
color: #000000;
color: rgba(0, 0, 0, 0.65);
}
}
}
......
......@@ -104,8 +104,8 @@
</div>
</div>
<div v-if="item.showType == 4" class="mid-text">
{{item.suffix}}
<span class="link">{{item.text}}</span>
{{item.text}}
<span class="link">{{item.suffix}}</span>
</div>
<div v-if="item.showType == 5" class="mid-text no-support">
<img src="../../../assets/image/IM/icon-warning-circle.png" alt />
......@@ -118,7 +118,7 @@
v-if="item.sendOrReceive && item.isShowErrorMsg"
class="error-mg"
:class="{'mr': item.sendOrReceive}"
>{{item.isErrorMsg}}</span>
>{{item.errorMsg}}</span>
</article>
</section>
<section class="c-bottom">
......@@ -211,9 +211,10 @@ import { getPicaKFAccid, getPhomeDemain } from "@/utils";
import UserInfo from "@/components/IM/user-info.vue";
// const CONTAINER_HEIGHT = 300;
const CONTAINER_HEIGHT = 700;
let forwardMsgIntervalId = null;
let sessionIntervalId = null;
let continueIntervalId = null;
let forwardMsgIntervalId = null,
sessionIntervalId = null,
continueIntervalId = null,
autoCompletionIntervalId = null;
let _this = null;
export default {
......@@ -287,6 +288,7 @@ export default {
deep: true
},
},
created() {
_this = this;
this.picakfAccId = getPicaKFAccid();
......@@ -298,6 +300,11 @@ export default {
}, 10000);
this.getFiveContentList();
autoCompletionIntervalId && clearInterval(autoCompletionIntervalId);
autoCompletionIntervalId = setInterval(() => {
this.autoCompletionInterval();
}, 30000);
// 监听键盘的回车按键(回车时发送消息,并阻止其在textarea中的回车换行行为)
document.onkeydown = function(ev) {
var event = ev || event;
......@@ -323,6 +330,43 @@ export default {
//
...mapMutations(["SET_IS_FROM_ASSIGN_TASK"]),
// 含有敏感信息的消息,自行补全提示文案
// 每30秒监测敏感信息
autoCompletionInterval() {
if(!this.messageList) return;
let flag = false, msg;
for(let i = 0; i < this.messageList.length; i ++) {
msg = messageList[i];
if(msg.isShowErrorIcon && !msg.isShowErrorMsg) {
flag = true;
}
}
if(flag) {
this.getMSGForwardForAC(msg);
}
},
// 查询医生和居民的消息 - 向前查找
// 将获取消息列表插入到当前消息列表的最后
getMSGForwardForAC() {
let session = this.currentSession;
let params = {
doctorAccId: this.currentToAccId,
includeFlag: 0,
lastClientIdServer: session.lastMsgIdClient,
lastMsgIdServer: session.lastMsgIdServer,
lastMsgTimestamp: msg.realTimestamp,
limit: 20,
patientAccId: this.picakfAccId,
unionId: ""
};
this.POST("/im/msg/forward", params).then(res => {
if (res.code === "000000") {
this.contactForwardMessage(res.data, false);
}
});
},
// 获取元素
getElmByID(elmId) {
return document.getElementById(elmId);
......@@ -338,8 +382,8 @@ export default {
let msg = Object.assign({}, params);
msg.fromAccount = this.currentToAccId;
msg.toAccount = this.picakfAccId;
msg.text = params.info;
msg.suffix = params.remark;
msg.text = params.info;
msg.size = params.fileSize;
msg.url = params.url;
msg.showType = params.type - 0 + 1;
......@@ -489,6 +533,7 @@ export default {
url = content.url;
} else if (content.bizType == 19) {
showType = 4;
text = content.content;
suffix = content.suffix;
} else {
showType = 5;
......@@ -562,7 +607,7 @@ export default {
},
// 接接数据
contactForwardMessage(cMessageList) {
contactForwardMessage(cMessageList, canPush = true) {
let content = {},
signature = "",
msgIndex = -1,
......@@ -582,7 +627,7 @@ export default {
});
if (msgIndex > -1) {
flag = true;
this.messageList[msgIndex].isErrorMsg = content.content;
this.messageList[msgIndex].errorMsg = content.content;
this.messageList[msgIndex].isShowErrorMsg = true;
}
this.$forceUpdate();
......@@ -592,7 +637,7 @@ export default {
}
} else {
flag = true;
this.messageList.push(item);
canPush && this.messageList.push(item);
}
});
if (flag) {
......
Markdown 格式
0% or
您添加了 0 到此讨论。请谨慎行事。
先完成此消息的编辑!
想要评论请 注册