...
|
...
|
@@ -227,33 +227,32 @@ var _loadPage = function() { |
|
|
|
|
|
/**
|
|
|
* 人工链接
|
|
|
* @param msgType 内部消息类型
|
|
|
* @param message 内部消息对象
|
|
|
* @param rec 接收对象
|
|
|
* @private
|
|
|
*/
|
|
|
function linkSuccess(msgType, message) {
|
|
|
function linkSuccess(rec) {
|
|
|
|
|
|
var OUT_SERVICE = 0, // 0 没上班
|
|
|
LINE_UP = 1, // 1 需要排队
|
|
|
MANUAL_SERVICE = 2, // 2 接入人工
|
|
|
ADMIN_MANUAL_SERVICE = 3; // 3 管理员分配
|
|
|
|
|
|
var OUT_SERVICE = 0,
|
|
|
LINE_UP = 1,
|
|
|
MANUAL_SERVICE = 2,
|
|
|
ADMIN_MANUAL_SERVICE = 3;
|
|
|
var message = rec.chatMessage;
|
|
|
var msgType = message.type;
|
|
|
|
|
|
var dom,
|
|
|
tipText;
|
|
|
|
|
|
switch (msgType) {
|
|
|
|
|
|
case OUT_SERVICE: // 0是没上班
|
|
|
tipText = message.content +
|
|
|
'您也可以选择<a class="leave-msg">留言</a>';
|
|
|
case OUT_SERVICE:
|
|
|
tipText = receive.leaMsgTip(rec);
|
|
|
dom = tipTpl({
|
|
|
content: tipText
|
|
|
});
|
|
|
break;
|
|
|
|
|
|
case LINE_UP: // 1是需要排队
|
|
|
tipText = message.content +
|
|
|
'您也可以选择<a class="leave-msg">留言</a>';
|
|
|
case LINE_UP:
|
|
|
tipText = receive.leaMsgTip(rec);
|
|
|
dom = tipTpl({
|
|
|
content: tipText
|
|
|
});
|
...
|
...
|
@@ -264,7 +263,7 @@ var _loadPage = function() { |
|
|
});
|
|
|
break;
|
|
|
|
|
|
case MANUAL_SERVICE: // 2是接入人工成功
|
|
|
case MANUAL_SERVICE:
|
|
|
tipText = message.content;
|
|
|
dom = tipTpl({
|
|
|
content: tipText
|
...
|
...
|
@@ -282,7 +281,7 @@ var _loadPage = function() { |
|
|
});
|
|
|
break;
|
|
|
|
|
|
case ADMIN_MANUAL_SERVICE: // 3是管理员分配客服成功
|
|
|
case ADMIN_MANUAL_SERVICE:
|
|
|
tipText = message.content;
|
|
|
dom = tipTpl({
|
|
|
content: tipText
|
...
|
...
|
@@ -482,7 +481,7 @@ var _loadPage = function() { |
|
|
break;
|
|
|
|
|
|
case allTypes.LINK_SUCCESS:
|
|
|
linkSuccess(msgType, message);
|
|
|
linkSuccess(rec);
|
|
|
break;
|
|
|
|
|
|
case allTypes.IN_QUNEUE:
|
...
|
...
|
|