|
|
@@ -46,46 +46,22 @@
|
|
|
<el-collapse-item class="list" v-for="item in knowLedgeBase" :key="item.id">
|
|
|
<template slot="title">
|
|
|
<div style="width:100%;" class="quesTit">
|
|
|
- <span>{{item.content}}</span>
|
|
|
- <span>{{item.add_time}}</span>
|
|
|
+ <span class="title">{{item.content}}</span>
|
|
|
+ <span style="float: right">{{item.add_time}}</span>
|
|
|
</div>
|
|
|
</template>
|
|
|
- <div>
|
|
|
- <div class="conversationBox">
|
|
|
- <div class="timer">
|
|
|
- {{item.add_time}}
|
|
|
- </div>
|
|
|
- <div class="customer row allAlignment">
|
|
|
- <div></div>
|
|
|
- <div class="row">
|
|
|
- <div class="cont right">
|
|
|
- <div>{{item.content}}</div>
|
|
|
- </div>
|
|
|
- <div class="headImg" style="margin-right:0">
|
|
|
- <img src="./../assets/st-img/user.png" alt="">
|
|
|
- </div>
|
|
|
- </div>
|
|
|
- </div>
|
|
|
- </div>
|
|
|
- <div class="conversationBox">
|
|
|
- <div class="timer">
|
|
|
- {{item.dealWith_time}}
|
|
|
- </div>
|
|
|
- <div class=" row">
|
|
|
- <div class="conversation row">
|
|
|
- <div class="headImg">
|
|
|
- <img src="./../assets/st-img/headAdvent.png" alt="">
|
|
|
- </div>
|
|
|
- <div class="cont left">
|
|
|
- <div>{{item.reply_content}}</div>
|
|
|
- </div>
|
|
|
-
|
|
|
- </div>
|
|
|
- <div style="width:66px;"></div>
|
|
|
- </div>
|
|
|
- </div>
|
|
|
+ <div class="text">
|
|
|
+ {{item.content}}
|
|
|
+ </div>
|
|
|
+ <ul class="imgs" v-for="i in imgs">
|
|
|
+ <li v-for="child in i">
|
|
|
+ <img :src="url + child" alt="">
|
|
|
+ </li>
|
|
|
+ </ul>
|
|
|
+ <p>回复的留言</p>
|
|
|
+ <div class="text">
|
|
|
+ {{item.reply_content ? item.reply_content : "暂无"}}
|
|
|
</div>
|
|
|
-
|
|
|
</el-collapse-item>
|
|
|
</el-collapse>
|
|
|
</div>
|
|
|
@@ -128,7 +104,10 @@
|
|
|
problemType: '', //类
|
|
|
knowLedgeBase: '', //知识库问答数据
|
|
|
problemName: '账号',//类名
|
|
|
- noBase: true //无数据状态
|
|
|
+ noBase: true , //无数据状态
|
|
|
+ imgs:[],
|
|
|
+ url: 'http://kfadmin.bocai186.com', // 域名地址
|
|
|
+ // url: 'http://192.168.2.187:8090', // 域名地址
|
|
|
}
|
|
|
},
|
|
|
methods: {
|
|
|
@@ -154,14 +133,23 @@
|
|
|
getLeave(data) {
|
|
|
this.$axios.post('/api/index/Message/index', data).then(res => {
|
|
|
if (res.data.status === 1) {
|
|
|
+ console.log('======获取数据=========', res.data.data);
|
|
|
+ let _img;
|
|
|
+ for (let i = 0; i < res.data.data.length; i++) {
|
|
|
+ _img = res.data.data[i].images.split(",");
|
|
|
+ this.imgs.push(_img)
|
|
|
+ }
|
|
|
+ console.log(this.imgs,'123123');
|
|
|
+
|
|
|
this.knowLedgeBase = res.data.data;
|
|
|
- if (this.knowLedgeBase.length > 0) {
|
|
|
+
|
|
|
+ if(this.knowLedgeBase.length > 0) {
|
|
|
this.noBase = true;
|
|
|
} else {
|
|
|
this.noBase = false;
|
|
|
}
|
|
|
}
|
|
|
- console.log('======获取数据=========', res);
|
|
|
+
|
|
|
})
|
|
|
},
|
|
|
// 查询数据
|
|
|
@@ -205,6 +193,38 @@
|
|
|
}
|
|
|
</script>
|
|
|
<style scoped>
|
|
|
+ .title {
|
|
|
+ float: left; width: 300px;
|
|
|
+ overflow-y: hidden;
|
|
|
+ word-break: keep-all;
|
|
|
+ white-space:nowrap;
|
|
|
+ text-overflow:ellipsis;
|
|
|
+ }
|
|
|
+ .imgs {
|
|
|
+ margin: 20px 0;
|
|
|
+ display: flex;
|
|
|
+ justify-content: flex-start;
|
|
|
+ }
|
|
|
+
|
|
|
+ .imgs li {
|
|
|
+ margin-right: 10px;
|
|
|
+ width: 100px;
|
|
|
+ height: 100px;
|
|
|
+ }
|
|
|
+ .imgs li img {
|
|
|
+ width: 100px;
|
|
|
+ height: 100px;
|
|
|
+ }
|
|
|
+ .text {
|
|
|
+ background: #f5f5f5;
|
|
|
+ border: 1px solid #eee;
|
|
|
+ padding: 20px;
|
|
|
+ font-size: 14px;
|
|
|
+ color: #666;
|
|
|
+ line-height: 1.8;
|
|
|
+ margin-right: 15px;
|
|
|
+ margin-top: 15px;
|
|
|
+ }
|
|
|
.chatBox {
|
|
|
width: 700px;
|
|
|
}
|
|
|
@@ -325,7 +345,6 @@
|
|
|
|
|
|
.el-main .leaveCont {
|
|
|
box-sizing: border-box;
|
|
|
- height: 510px;
|
|
|
padding: 20px 20px 13px;
|
|
|
}
|
|
|
|
|
|
@@ -439,8 +458,6 @@
|
|
|
|
|
|
.list .quesTit {
|
|
|
height: 40px;;
|
|
|
- display: flex;
|
|
|
- justify-content: space-between;
|
|
|
align-items: center;
|
|
|
}
|
|
|
|