Commit e677db5d by 怪兽?别跑

bug修复

1 parent df212675
...@@ -9,7 +9,8 @@ ...@@ -9,7 +9,8 @@
start-placeholder="开始日期" start-placeholder="开始日期"
end-placeholder="结束日期" end-placeholder="结束日期"
align="right" align="right"
@change="getList(1)"></el-date-picker> @change="getList(1)"
></el-date-picker>
<div class="list"> <div class="list">
<template v-if="list.length"> <template v-if="list.length">
<chatList :queryChat="queryChat" v-if="'all,image,video,link,'.includes(type)" :data="list"></chatList> <chatList :queryChat="queryChat" v-if="'all,image,video,link,'.includes(type)" :data="list"></chatList>
...@@ -18,8 +19,9 @@ ...@@ -18,8 +19,9 @@
v-else-if="type == 'file'" v-else-if="type == 'file'"
:data="list" :data="list"
stripe stripe
style="width: 100%" style="width: 100%;"
:header-cell-style="{ background: '#fff' }"> :header-cell-style="{ background: '#fff' }"
>
<!-- <el-table-column prop="msgtype" label="类型"> </el-table-column> --> <!-- <el-table-column prop="msgtype" label="类型"> </el-table-column> -->
<el-table-column label="名称"> <el-table-column label="名称">
<template slot-scope="{ row }"> <template slot-scope="{ row }">
...@@ -36,6 +38,11 @@ ...@@ -36,6 +38,11 @@
{{ row.name }} {{ row.name }}
</template> </template>
</el-table-column> </el-table-column>
<el-table-column label="发送时间">
<template slot-scope="{ row }">
{{ row.msgTime }}
</template>
</el-table-column>
<el-table-column prop="action" label="操作"> <el-table-column prop="action" label="操作">
<template slot-scope="{ row }"> <template slot-scope="{ row }">
<el-button type="text" @click="downloadFile(row)">下载</el-button> <el-button type="text" @click="downloadFile(row)">下载</el-button>
...@@ -47,7 +54,8 @@ ...@@ -47,7 +54,8 @@
v-else-if="'voice,meeting_voice_call'.includes(type)" v-else-if="'voice,meeting_voice_call'.includes(type)"
:data="list" :data="list"
stripe stripe
:header-cell-style="{ background: '#fff' }"> :header-cell-style="{ background: '#fff' }"
>
<el-table-column prop="date" label="发起人"> <el-table-column prop="date" label="发起人">
<template slot-scope="{ row }"> <template slot-scope="{ row }">
{{ row.name }} {{ row.name }}
...@@ -100,31 +108,32 @@ ...@@ -100,31 +108,32 @@
layout="prev, pager, next" layout="prev, pager, next"
:current-page.sync="currentPage" :current-page.sync="currentPage"
@current-change="getList" @current-change="getList"
:total="total" /> :total="total"
/>
</div> </div>
</template> </template>
<script> <script>
import chatList from './chatList.vue' import chatList from './chatList.vue'
import * as api from '@/api/conversation/content.js' import * as api from '@/api/conversation/content.js'
import Voice from '@/components/Voice' import Voice from '@/components/Voice'
import { download } from '@/api/common.js' import { download } from '@/api/common.js'
import { diffDate } from '@/utils/index' import { diffDate } from '@/utils/index'
import { parseTime } from '@/utils/common' import { parseTime } from '@/utils/common'
export default { export default {
name: '', name: '',
components: { chatList, Voice }, components: { chatList, Voice },
props: { props: {
// 消息收发者 // 消息收发者
queryChat: { queryChat: {
type: Object, type: Object,
default: () => ({}), default: () => ({})
}, },
// 消息类型 // 消息类型
type: { type: {
type: String | Number, type: String | Number,
default: 0, default: 0
}, }
}, },
data() { data() {
return { return {
...@@ -132,14 +141,14 @@ export default { ...@@ -132,14 +141,14 @@ export default {
currentPage: 1, currentPage: 1,
dateRange: [], dateRange: [],
list: [], list: [],
total: 0, total: 0
} }
}, },
computed: {}, computed: {},
watch: { watch: {
queryChat() { queryChat() {
this.getList(1) this.getList(1)
}, }
}, },
created() { created() {
this.getList(1) this.getList(1)
...@@ -159,7 +168,7 @@ export default { ...@@ -159,7 +168,7 @@ export default {
msgType: this.type == 'all' ? '' : this.type, msgType: this.type == 'all' ? '' : this.type,
pageSize: '10', pageSize: '10',
orderByColumn: 't.msg_time', orderByColumn: 't.msg_time',
isAsc: 'desc', isAsc: 'desc'
} }
if (this.dateRange) { if (this.dateRange) {
query.beginTime = this.dateRange[0] query.beginTime = this.dateRange[0]
...@@ -196,19 +205,19 @@ export default { ...@@ -196,19 +205,19 @@ export default {
this.$confirm('是否确认下载该文件?', '警告', { this.$confirm('是否确认下载该文件?', '警告', {
confirmButtonText: '确定', confirmButtonText: '确定',
cancelButtonText: '取消', cancelButtonText: '取消',
type: 'warning', type: 'warning'
}) })
.then((response) => { .then((response) => {
this.downloadNet(JSON.parse(row.contact).attachment, JSON.parse(row.contact).filename) this.downloadNet(JSON.parse(row.contact).attachment, JSON.parse(row.contact).filename)
}) })
.catch(function () {}) .catch(function () {})
}, }
}, }
} }
</script> </script>
<style lang="scss" scoped> <style lang="scss" scoped>
.list { .list {
height: calc(100vh - 420px); height: calc(100vh - 420px);
margin-top: 10px; margin-top: 10px;
background: white; background: white;
...@@ -220,10 +229,10 @@ export default { ...@@ -220,10 +229,10 @@ export default {
::-webkit-scrollbar { ::-webkit-scrollbar {
display: none; display: none;
} }
} }
.chatListClassTab { .chatListClassTab {
padding: 10px 10px 0; padding: 10px 10px 0;
background: #fff; background: #fff;
text-align: left; text-align: left;
} }
</style> </style>
...@@ -12,7 +12,7 @@ ...@@ -12,7 +12,7 @@
<el-table :data="dataList" @selection-change="handleSelectionChange"> <el-table :data="dataList" @selection-change="handleSelectionChange">
<el-table-column type="selection" width="55" align="center" /> <el-table-column type="selection" width="55" align="center" />
<el-table-column label="员工名称" align="center" prop="businessName" show-overflow-tooltip /> <el-table-column label="员工名称" align="center" prop="businessName" show-overflow-tooltip />
<el-table-column label="每日添加上线" align="center" width="150" prop="businessNumber" show-overflow-tooltip> <el-table-column label="每日添加上限" align="center" width="150" prop="businessNumber" show-overflow-tooltip>
<template slot-scope="scope"> <template slot-scope="scope">
<el-input-number <el-input-number
size="mini" size="mini"
......
Markdown is supported
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!