客服界面增加按钮

pull/23/head
taoshihan1991 4 years ago
parent 2e78405285
commit 0b0a69d749

@ -59,6 +59,7 @@
.chatArea{margin: 10px 0;} .chatArea{margin: 10px 0;}
.chatBox{max-height: 350px;overflow-y: auto;overflow-x: hidden;} .chatBox{max-height: 350px;overflow-y: auto;overflow-x: hidden;}
.chatTime{text-align: center;color: #bbb;margin: 5px 0;font-size: 12px;} .chatTime{text-align: center;color: #bbb;margin: 5px 0;font-size: 12px;}
.funcBtns{margin: 2px 0px;color: #7f7f7f;border-bottom: 1px solid #e6e6e6;font-size: 12px;padding: 5px 0px;}
</style> </style>
</head> </head>
<body> <body>
@ -107,9 +108,16 @@
<el-col :span="12"> <el-col :span="12">
<div class="sw-bg chatBgContext"> <div class="sw-bg chatBgContext">
<el-alert <el-alert
:closable="false"
:type="chatTitleType"
show-icon
:title="chatTitle" :title="chatTitle"
type="success"> >
</el-alert> </el-alert>
<div class="funcBtns" v-show="visitor.visitor_id">
<el-button size="small" type="success" plain icon="el-icon-position">转接</el-button>
<el-button v-on:click="closeVisitor(visitor.visitor_id)" size="small" type="success" plain icon="el-icon-close">结束</el-button>
</div>
<div class="chatBox"> <div class="chatBox">
<el-row :gutter="2" v-for="v in msgList" v-bind:class="{'chatBoxMe': v.is_kefu==true}"> <el-row :gutter="2" v-for="v in msgList" v-bind:class="{'chatBoxMe': v.is_kefu==true}">
<div class="chatTime"><{v.time}></div> <div class="chatTime"><{v.time}></div>
@ -208,5 +216,5 @@
</template> </template>
</div> </div>
</body> </body>
<script src="/static/js/chat-main.js?v=0.3.4"></script> <script src="/static/js/chat-main.js?v=0.3.5"></script>
</html> </html>

@ -2,6 +2,7 @@ var app=new Vue({
el: '#app', el: '#app',
delimiters:["<{","}>"], delimiters:["<{","}>"],
data: { data: {
chatTitleType:"info",
fullscreenLoading:true, fullscreenLoading:true,
leftTabActive:"first", leftTabActive:"first",
rightTabActive:"visitorInfo", rightTabActive:"visitorInfo",
@ -161,7 +162,7 @@ var app=new Vue({
//接手客户 //接手客户
talkTo(guestId,name) { talkTo(guestId,name) {
this.currentGuest = guestId; this.currentGuest = guestId;
this.chatTitle=name+"|"+guestId+",正在处理中..."; //this.chatTitle=name+"|"+guestId+",正在处理中...";
//发送给客户 //发送给客户
let mes = {} let mes = {}
@ -376,6 +377,8 @@ var app=new Vue({
// _this.visitor.source_ip=r.source_ip; // _this.visitor.source_ip=r.source_ip;
_this.visitor.status=r.status==1?"在线":"离线"; _this.visitor.status=r.status==1?"在线":"离线";
//_this.visitor.visitor_id=r.visitor_id; //_this.visitor.visitor_id=r.visitor_id;
_this.chatTitle="#"+r.id+"|"+r.name;
_this.chatTitleType="success";
} }
if(data.code!=200){ if(data.code!=200){
_this.$message({ _this.$message({

Loading…
Cancel
Save