Commit 5e8a5879 authored by 赵啸非's avatar 赵啸非

Merge remote-tracking branch 'origin/master'

parents c320cc86 1c98fc0d
......@@ -70,6 +70,18 @@ export function getWLLZInfo(params) {
export function getSys12345(params) {
return http.get(`${BASEURL}/wllz/complainapi/sys12345`, params);
}
// 12345查询受理类型
export function getType(params) {
return http.get(`${BASEURL}/inter/sys12345/getType`, params);
}
// 12345查询写信详情
export function letterInfo(params) {
return http.get(`${BASEURL}/inter/sys12345/letterInfo`, params);
}
// 12345写信报表
export function adminList(params) {
return http.post(`${BASEURL}/inter/sys12345/adminList`, params);
}
// 样表列表
export function getBillList(params) {
......
......@@ -17,17 +17,26 @@
<span>
<a-select v-model="status" style="margin: 0 10px">
<a-select-option value=""> 全部类型 </a-select-option>
<a-select-option value="0"> 离线 </a-select-option>
<a-select-option
v-for="val in typeList"
:key="val.value"
:value="val.value"
>
{{ val.name }}
</a-select-option>
</a-select>
<a-select v-model="source">
<a-select-option value=""> 全部来源 </a-select-option>
<a-select-option value="0"> 离线 </a-select-option>
<a-select-option value="1"> 微官网 </a-select-option>
<a-select-option value="2"> 自助服务系统 </a-select-option>
<a-select-option value="1"> 数字填单系统 </a-select-option>
</a-select>
<a-range-picker
format="YYYY-MM-DD"
class="range_picker_style"
@change="rangePickerChange"
style="margin: 0 10px"
v-model="timeList"
>
</a-range-picker>
......@@ -79,13 +88,44 @@
<script>
import table from "@/mixins/table";
import { getSys12345 } from "@/api/dataAdmin";
import { adminList, getType, letterInfo } from "@/api/dataAdmin";
import { export2Excel } from "@/utils/js/exportExcel";
import FormDetails from "./components/FormDetails.vue";
const tHeader = [
"序号",
"工单编号",
"信件标题",
"信件类别",
"姓名",
"性别",
"联系电话",
"信件来源",
"提交时间",
"办理状态",
"办理时间",
"办理部门",
];
const filterVal = [
"index",
"LetterCode",
"strTitle",
"strType",
"strUserName",
"strGender",
"strPhone",
"source",
"create_time",
"status",
"update_time",
"AcceptName",
];
export default {
mixins: [table],
name: "callRecordForm",
data() {
return {
timeList: [],
status: "",
source: "",
tableHeaders: [
......@@ -100,48 +140,67 @@ export default {
{
title: "工单编号",
align: "center",
dataIndex: "nickname",
customRender: (text, record, index) => `${record.nickname || "--"}`,
dataIndex: "LetterCode",
customRender: (text, record, index) => `${record.LetterCode || "--"}`,
},
{
title: "信件标题",
align: "center",
dataIndex: "phone",
customRender: (text, record, index) => `${record.phone || "--"}`,
dataIndex: "strTitle",
customRender: (text, record, index) => `${record.strTitle || "--"}`,
},
{
title: "信件类别",
align: "center",
dataIndex: "address",
customRender: (text, record, index) => `${record.address || "--"}`,
dataIndex: "strType",
customRender: (text, record, index) => `${record.strType || "--"}`,
},
{
title: "姓名",
align: "center",
dataIndex: "create_time",
dataIndex: "strUserName",
customRender: (text, record, index) =>
`${record.create_time || "--"}`,
`${record.strUserName || "--"}`,
},
{
title: "性别",
align: "center",
dataIndex: "create_time",
dataIndex: "strGender",
customRender: (text, record, index) =>
`${record.create_time || "--"}`,
`${
record.strGender
? record.strGender == 0
? ""
: record.strGender == 1
? ""
: record.strGender == 2
? ""
: "--"
: "--"
}`,
},
{
title: "联系电话",
align: "center",
dataIndex: "create_time",
customRender: (text, record, index) =>
`${record.create_time || "--"}`,
dataIndex: "strPhone",
customRender: (text, record, index) => `${record.strPhone || "--"}`,
},
{
title: "信件来源",
align: "center",
dataIndex: "create_time",
dataIndex: "source",
customRender: (text, record, index) =>
`${record.create_time || "--"}`,
`${
record.source
? record.source == 1
? "微官网"
: record.source == 2
? "自助服务系统"
: record.source == 3
? "数字填单系统"
: "--"
: "--"
}`,
},
{
title: "提交时间",
......@@ -153,23 +212,21 @@ export default {
{
title: "办理状态",
align: "center",
dataIndex: "create_time",
customRender: (text, record, index) =>
`${record.create_time || "--"}`,
dataIndex: "status",
customRender: (text, record, index) => `${record.status || "--"}`,
},
{
title: "办理时间",
align: "center",
dataIndex: "create_time",
dataIndex: "update_time",
customRender: (text, record, index) =>
`${record.create_time || "--"}`,
`${record.update_time || "--"}`,
},
{
title: "办理部门",
align: "center",
dataIndex: "create_time",
customRender: (text, record, index) =>
`${record.create_time || "--"}`,
dataIndex: "AcceptName",
customRender: (text, record, index) => `${record.AcceptName || "--"}`,
},
{
title: "操作",
......@@ -187,23 +244,49 @@ export default {
searchName: undefined,
visible: false,
total: 0,
typeList: [],
};
},
components: {},
mounted() {
this.getList();
this.timeList = [
this.$moment().format("YYYY-MM-DD"),
this.$moment().format("YYYY-MM-DD"),
];
getType().then((res) => {
console.log(res);
res.data ? (this.typeList = res.data) : (this.typeList = []);
});
},
components: {
FormDetails,
},
methods: {
getList() {
getSys12345({
phone: this.searchName,
adminList({
keyword: this.searchName,
page: this.tablePagination.current,
size: this.tablePagination.pageSize,
strTypeID: this.status,
source: this.source,
time: this.timeList,
}).then((res) => {
this.tableSourceData = res.data.data;
this.tablePagination.total = res.data.total;
this.total = res.data.total;
});
},
// 页面跳转
pagTableChange(pagination) {
this.tablePagination = pagination;
this.getList();
},
rangePickerChange(val) {
console.log(val);
this.timeList = [
this.$moment(val[0]).format("YYYY-MM-DD"),
this.$moment(val[1]).format("YYYY-MM-DD"),
];
},
QueueState(type) {
switch (type) {
......@@ -247,12 +330,17 @@ export default {
});
} else {
let datas = this.$_.cloneDeep(
await getSys12345({
page: 1,
size: -1,
await adminList({
keyword: this.searchName,
page: this.tablePagination.current,
size: this.tablePagination.pageSize,
strTypeID: this.status,
source: this.source,
time: this.timeList,
})
);
data = datas.data.data;
if (!data.length) return;
for (let item of data) {
Object.keys(obj).forEach((key) => {
......@@ -262,15 +350,40 @@ export default {
});
}
}
data.forEach((record, i) => {
record.index = i + 1;
record.source = record.source
? record.source == 1
? "微官网"
: record.source == 2
? "自助服务系统"
: record.source == 3
? "数字填单系统"
: "--"
: "--";
record.strGender = record.strGender
? record.strGender == 0
? ""
: record.strGender == 1
? ""
: record.strGender == 2
? ""
: "--"
: "--";
});
export2Excel(
this.tHeader,
this.filterVal,
tHeader,
filterVal,
data,
"填单记录报表" + this.$moment().format("YYYYMMDDHHmmss")
);
this.btnLoading = false;
},
showDrawer(val) {
letterInfo({ id: val.id }).then((res) => {
console.log(res);
res.data ? (this.$refs.FormDetails.fromData = res.data) : "";
});
this.visible = true;
},
onClose() {
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment