Commit ceb5207d by 施宇

1

Signed-off-by: shiyu <847476962@qq.com>
parent 1c3f4f35
Showing with 8 additions and 3 deletions
...@@ -453,6 +453,7 @@ $(function () { ...@@ -453,6 +453,7 @@ $(function () {
}, },
fail: function (e) { fail: function (e) {
console.log("Send private text failed", e); console.log("Send private text failed", e);
layer.msg('消息发送失败');
} }
}); });
this.conn.send(msg.body); this.conn.send(msg.body);
...@@ -478,6 +479,7 @@ $(function () { ...@@ -478,6 +479,7 @@ $(function () {
}, },
fail: function () { fail: function () {
console.log("Send Cmd failed"); console.log("Send Cmd failed");
layer.msg('消息发送失败');
} }
}); });
this.conn.send(msg.body); this.conn.send(msg.body);
...@@ -515,6 +517,10 @@ $(function () { ...@@ -515,6 +517,10 @@ $(function () {
$('#' + userId).find('.notice_list').scrollTop(contentHeight); $('#' + userId).find('.notice_list').scrollTop(contentHeight);
$('#img_upload').val(''); $('#img_upload').val('');
}, },
fail: function () {
console.log("Send Image failed");
layer.msg('消息发送失败');
}
}; };
msg.set(option); msg.set(option);
this.conn.send(msg.body); this.conn.send(msg.body);
...@@ -572,7 +578,7 @@ $(function () { ...@@ -572,7 +578,7 @@ $(function () {
if (self.isLoginSuccess) { //登入成功 获取聊天记录 if (self.isLoginSuccess) { //登入成功 获取聊天记录
self.getHistoryData(id,isTemplate) self.getHistoryData(id,isTemplate)
} else { } else {
layer.msg('获取聊天记录失败'); layer.msg('聊天系统出错');
return; return;
} }
}); });
...@@ -585,9 +591,8 @@ $(function () { ...@@ -585,9 +591,8 @@ $(function () {
var self = this; var self = this;
this.conn.fetchHistoryMessages({ this.conn.fetchHistoryMessages({
queue: id, queue: id,
count: "100", count: "50",
success: function (data) { success: function (data) {
console.log('xixixi')
self.rendHistoryMessage(id, data) self.rendHistoryMessage(id, data)
if(isTemplate){ if(isTemplate){
self.sendCmd(self.templateObj); self.sendCmd(self.templateObj);
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or sign in to comment