Commit da260e66 by xinla

--no commit message

1 parent cb704f58
...@@ -225,7 +225,7 @@ export default { ...@@ -225,7 +225,7 @@ export default {
this.searchResult = [] this.searchResult = []
apiOrg apiOrg
.getDeptUser({ .getDeptUser({
deptId: this.defaultExpandedKeys[0], // deptId: this.defaultExpandedKeys[0],
userName: this.keywords, userName: this.keywords,
}) })
.then((res) => { .then((res) => {
......
...@@ -53,24 +53,20 @@ ...@@ -53,24 +53,20 @@
<el-time-select <el-time-select
style="width: 130px;" style="width: 130px;"
v-model="item.beginTime" v-model="item.beginTime"
:picker-options="{ start="00:00"
start: '00:00', end="23:59"
end: '23:59', step="00:30"
step: '00:30', :max-time="item.endTime"
maxTime: item.endTime
}"
@change="checkStartEnd($event, index)" @change="checkStartEnd($event, index)"
placeholder="任意时间点" placeholder="任意时间点"
></el-time-select> ></el-time-select>
-- --
<el-time-select <el-time-select
style="width: 130px;" style="width: 130px;"
:picker-options="{ start="00:00"
start: '00:00', end="23:59"
end: '23:59', step="00:30"
step: '00:30', :min-time="item.beginTime"
minTime: item.beginTime
}"
@change="checkStartEnd($event, index)" @change="checkStartEnd($event, index)"
v-model="item.endTime" v-model="item.endTime"
placeholder="任意时间点" placeholder="任意时间点"
......
...@@ -21,7 +21,8 @@ ...@@ -21,7 +21,8 @@
range-separator="-" range-separator="-"
@change="setDateChange" @change="setDateChange"
start-placeholder="开始日期" start-placeholder="开始日期"
end-placeholder="结束日期"></el-date-picker> end-placeholder="结束日期"
></el-date-picker>
</el-form-item> </el-form-item>
<el-form-item label=""> <el-form-item label="">
<el-button type="primary" @click="handleSearch">查询</el-button> <el-button type="primary" @click="handleSearch">查询</el-button>
...@@ -45,7 +46,7 @@ ...@@ -45,7 +46,7 @@
</el-table-column> </el-table-column>
<el-table-column label="质检会话类型" align="center" prop="chatType" min-width="160px"> <el-table-column label="质检会话类型" align="center" prop="chatType" min-width="160px">
<template #default="{ row }"> <template #default="{ row }">
{{ row.chatType == 1 ? '全部' : rew.chatType == 2 ? '客户会话' : '客群会话' }} {{ row.chatType == 1 ? '全部' : row.chatType == 2 ? '客户会话' : '客群会话' }}
</template> </template>
</el-table-column> </el-table-column>
<el-table-column label="质检督导" align="center" prop="manageUser" min-width="160px"> <el-table-column label="质检督导" align="center" prop="manageUser" min-width="160px">
...@@ -70,121 +71,122 @@ ...@@ -70,121 +71,122 @@
v-model:visible="dialogVisible" v-model:visible="dialogVisible"
title="组织架构" title="组织架构"
:defaultValues="userArray" :defaultValues="userArray"
@success="getSelectUser"></SelectUser> @success="getSelectUser"
></SelectUser>
</div> </div>
</template> </template>
<script> <script>
import { getList, deleteQuality } from './api.js' import { getList, deleteQuality } from './api.js'
export default { export default {
name: 'quality', name: 'quality',
data() { data() {
return { return {
query: { query: {
pageSize: 10, pageSize: 10,
pageNum: 1, pageNum: 1,
name: '', name: '',
userIds: '', userIds: '',
startTime: '', startTime: '',
endTime: '', endTime: '',
chatType: 1, chatType: 1
},
total: 0,
dialogVisible: false,
userName: '',
userArray: [],
searchDate: [],
list: [],
loading: false,
chatTypeArray: [
{
key: 1,
value: '全部',
},
{
key: 2,
value: '客户会话',
},
{
key: 3,
value: '客群会话',
}, },
], total: 0,
} dialogVisible: false,
}, userName: '',
created() { userArray: [],
this.getList() searchDate: [],
}, list: [],
methods: { loading: false,
getSelectUser(data) { chatTypeArray: [
this.userArray = data {
this.userName = this.userArray key: 1,
.map(function (obj, index) { value: '全部'
return obj.name },
}) {
.join(',') key: 2,
this.query.userIds = this.userArray value: '客户会话'
.map(function (obj, index) { },
return obj.userId {
}) key: 3,
.join(',') value: '客群会话'
}, }
setDateChange(data) { ]
if (data && data[0]) {
this.query.beginTime = data[0]
} else {
this.query.beginTime = ''
}
if (data && data[1]) {
this.query.endTime = data[1]
} else {
this.query.endTime = ''
} }
}, },
handleSearch() { created() {
this.query.pageNum = 1
this.getList()
},
getList() {
getList(this.query).then((res) => {
this.total = Number(res.total)
this.list = res.rows
})
},
resetQuery() {
this.query = {
pageSize: 10,
pageNum: 1,
name: '',
userIds: '',
startTime: '',
endTime: '',
chatType: 1,
}
this.userName = ''
this.userArray = []
this.getList() this.getList()
}, },
goRoute(path, id) { methods: {
this.$router.push({ path: path, query: { id } }) getSelectUser(data) {
}, this.userArray = data
removeFn(id) { this.userName = this.userArray
this.$confirm('是否确认删除当前质检规则?', '提示', { .map(function (obj, index) {
confirmButtonText: '确定', return obj.name
cancelButtonText: '取消', })
type: 'warning', .join(',')
}) this.query.userIds = this.userArray
.then(() => { .map(function (obj, index) {
return deleteQuality(id) return obj.userId
})
.join(',')
},
setDateChange(data) {
if (data && data[0]) {
this.query.beginTime = data[0]
} else {
this.query.beginTime = ''
}
if (data && data[1]) {
this.query.endTime = data[1]
} else {
this.query.endTime = ''
}
},
handleSearch() {
this.query.pageNum = 1
this.getList()
},
getList() {
getList(this.query).then((res) => {
this.total = Number(res.total)
this.list = res.rows
}) })
.then(() => { },
this.handleSearch() resetQuery() {
this.msgSuccess('删除成功') this.query = {
pageSize: 10,
pageNum: 1,
name: '',
userIds: '',
startTime: '',
endTime: '',
chatType: 1
}
this.userName = ''
this.userArray = []
this.getList()
},
goRoute(path, id) {
this.$router.push({ path: path, query: { id } })
},
removeFn(id) {
this.$confirm('是否确认删除当前质检规则?', '提示', {
confirmButtonText: '确定',
cancelButtonText: '取消',
type: 'warning'
}) })
.catch(function () {}) .then(() => {
}, return deleteQuality(id)
}, })
} .then(() => {
this.handleSearch()
this.msgSuccess('删除成功')
})
.catch(function () {})
}
}
}
</script> </script>
<style lang="scss" scoped></style> <style lang="scss" scoped></style>
Markdown is supported
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!