客服提示信息

master
taoshihan 2 years ago
parent 7a8cc9ab40
commit 0b0bcef2a7

@ -460,7 +460,7 @@ a{color: #07a9fe;text-decoration: none;}
align-items: center;
}
.chatEntBox {
width: calc(100% - 270px);
width: calc(100% - 265px);
float: left;
border-right: 1px solid #e6e6e6;
}

@ -20,8 +20,6 @@ new Vue({
flyLang:GOFLY_LANG[LANG],
textareaFocused:false,
replys:[],
noticeName:"",
noticeAvatar:"",
showIconBtns:false,
showFaceIcon:false,
isIframe:false,
@ -31,7 +29,6 @@ new Vue({
//初始化websocket
initConn:function() {
let socket = new ReconnectingWebSocket(this.server+"?visitor_id="+this.visitor.visitor_id);//创建Socket实例
socket.maxReconnectAttempts = 30;
this.socket = socket
this.socket.onmessage = this.OnMessage;
this.socket.onopen = this.OnOpen;
@ -41,9 +38,8 @@ new Vue({
},
OnOpen:function() {
console.log("ws:onopen");
this.chatTitle=GOFLY_LANG[LANG]['connectok'];
this.showTitle(this.chatTitle);
//获取欢迎
this.getNotice();
this.socketClosed=false;
this.focusSendConn=false;
},
@ -227,8 +223,6 @@ new Vue({
_this.setCache("visitor",res.result);
//_this.getMesssagesByVisitorId();
_this.initConn();
//获取欢迎
_this.getNotice();
});
// }else{
// this.visitor=obj;
@ -343,13 +337,13 @@ new Vue({
var code=res.code;
if(code!=200) return;
_this.kefuInfo=res.result;
var welcome=res.result.welcome;
if(!welcome) return;
_this.showTitle(_this.kefuInfo.nickname+" 为您服务");
if(!_this.kefuInfo.welcome) return;
var msg={
content:replaceContent(welcome),
avator:res.result.avatar,
name :res.result.nickname,
time:new Date(),
content:replaceContent(_this.kefuInfo.welcome),
avator:_this.kefuInfo.avatar,
name :_this.kefuInfo.nickname,
time:_this.getNowDate(),
}
_this.msgList.push(msg);
_this.scrollBottom();

@ -11,10 +11,10 @@
<script src="https://cdn.staticfile.org/jquery/3.6.0/jquery.min.js"></script>
<script src="/assets/js/functions.js?v=0.1.1"></script>
<script src="/assets/js/functions.js?v=fgffdwersdccvcbv"></script>
<script src="/assets/js/reconnecting-websocket.min.js"></script>
<link rel="stylesheet" href="/static/css/front.css?v=1.0.0" />
<link rel="stylesheet" href="/static/css/common.css?v=1.0.0" />
<link rel="stylesheet" href="/static/css/common.css?v=sdsderfrgfgdfdf" />
<link rel="stylesheet" href="/static/css/icono.min.css" />
</head>
<body class="visitorBody">
@ -91,5 +91,5 @@
var LANG=checkLang();
</script>
<script src="/assets/js/chat-lang.js?v=0.3.7"></script>
<script src="/assets/js/chat-page.js?v=0.3.7"></script>
<script src="/assets/js/chat-page.js?v=rtyrhgfnykug"></script>
</html>

Loading…
Cancel
Save