Commit 02df282b authored by 赵啸非's avatar 赵啸非

Merge remote-tracking branch 'origin/master'

parents e479fa53 6b202c33
This diff is collapsed.
......@@ -25,6 +25,7 @@
"lodash": "^4.17.21",
"moment": "^2.29.4",
"qs": "^6.10.3",
"v-viewer": "^1.6.4",
"vue": "^2.6.14",
"vue-highlightjs": "^1.3.3",
"vue-router": "^3.5.1",
......
......@@ -41,6 +41,10 @@ Vue.prototype.$codeMap = codeMap;
Vue.prototype.$bus = new Vue();
Vue.config.productionTip = false;
// 图片预约
import Viewer from 'v-viewer'
import 'viewerjs/dist/viewer.css'
Vue.use(Viewer);
new Vue({
router,
store,
......
......@@ -5,7 +5,7 @@
<a-button :loading="btnLoading" type="success" @click="handleExportTable">
<span>{{ tableSelectedRows.length ? "导出" : "导出全部" }}</span>
</a-button>
<div class="ml20">提交次数:{{ numObj ? numObj.count : 0 }}</div>
<div class="ml20">提交次数:{{ numObj ? numObj.count : 0 }}</div>
<div class="ml20">回复次数:{{ numObj ? numObj.reply_count : 0 }}</div>
</div>
<a-form :model="queryform" layout="inline">
......@@ -29,29 +29,29 @@
<a-button type="primary" @click="getlist">搜索</a-button>
</a-form-item>
</a-form>
</div>
<div class="table-box">
<a-table :dataSource="tabledataSource" :columns="tablecolumns" :pagination="pagination" :scroll="{ y: 590 }"
:row-key="(record) => record.id" @change="changeTablePage" :row-selection="{
selectedRowKeys: tableSelectedKeys,
onChange: onSelectChange,
}">
<template slot="type" slot-scope="text, record, index">
<div>{{typeList.find(item=>record.type).label}}</div>
</template>
<template slot="valid" slot-scope="text, record, index">
<div>{{record.valid == 1 ? '' : ''}}</div>
</template>
<template slot="secrecy" slot-scope="text, record, index">
<div>{{record.secrecy == 1 ? '' : ''}}</div>
</template>
<template slot="status" slot-scope="text, record, index">
<div>{{record.status == 1 ? '' : ''}}</div>
</template>
<template slot="操作" slot-scope="text, record, index">
<a-button type="link" @click="detail(record)">详情</a-button>
</template>
</a-table>
</div>
<div class="table-box">
<a-table :dataSource="tabledataSource" :columns="tablecolumns" :pagination="pagination" :scroll="{ y: 590 }"
:row-key="(record) => record.id" @change="changeTablePage" :row-selection="{
selectedRowKeys: tableSelectedKeys,
onChange: onSelectChange,
}">
<template slot="type" slot-scope="text, record, index">
<div>{{typeList.find(item=>record.type).label}}</div>
</template>
<template slot="valid" slot-scope="text, record, index">
<div>{{record.valid == 1 ? '' : ''}}</div>
</template>
<template slot="secrecy" slot-scope="text, record, index">
<div>{{record.secrecy == 1 ? '' : ''}}</div>
</template>
<template slot="status" slot-scope="text, record, index">
<div>{{record.status == 1 ? '' : ''}}</div>
</template>
<template slot="操作" slot-scope="text, record, index">
<a-button type="link" @click="detail(record)">详情</a-button>
</template>
</a-table>
</div>
<a-drawer title="详情" :visible="visible" width="100%" @close="visible = false">
<div class="content-box">
......@@ -134,7 +134,7 @@
import image from '@/components/image/thumbImage'
import {
export2Excel
} from "@/utils/js/exportExcel";
} from "@/utils/js/exportExcel";
import moment from 'moment'
export default {
data() {
......@@ -145,7 +145,7 @@
size: 10,
source: '',
keyword: null,
time: [moment().format('yyyy-MM-DD'),moment().format('yyyy-MM-DD')],
time: [moment().format('yyyy-MM-DD'),moment().format('yyyy-MM-DD')],
reply:''
},
deviceList: [{
......@@ -165,9 +165,9 @@
title: "序号",
width: "70px",
align: 'center',
customRender: (text, record, index) =>
(this.queryform.page - 1) * this.queryform.size +
index +
customRender: (text, record, index) =>
(this.queryform.page - 1) * this.queryform.size +
index +
1,
},
......@@ -227,9 +227,9 @@
},
{
title: "所属部门",
dataIndex: "dept_name",
dataIndex: "reply_dept",
align: 'center',
customRender: (text, record, index) => `${record.dept_name || '--'}`
customRender: (text, record, index) => `${record.reply_dept || '--'}`
},
{
title: "操作",
......@@ -265,14 +265,14 @@
methods: {
getlist() {
getImpossible(this.queryform).then(res => {
this.tabledataSource = res.data.data
this.tabledataSource = res.data.data
this.pagination.total = res.data.total
})
},
changeTablePage(e) {
this.queryform.page = e.current
this.queryform.size = e.pageSize
this.getlist()
},
changeTablePage(e) {
this.queryform.page = e.current
this.queryform.size = e.pageSize
this.getlist()
},
onChange(e) {
this.queryform.reply = e.target.checked ? 0 : ''
......@@ -321,7 +321,7 @@
page: 1,
size: -1
})
);
);
data = datas.data.data
if (!data.length) return;
for (let item of data) {
......@@ -336,7 +336,7 @@
this.tHeader,
this.filterVal,
data,
"填单记录报表" + this.$moment().format("YYYYMMDDHHmmss")
"办不成事报表" + this.$moment().format("YYYYMMDDHHmmss")
);
this.btnLoading = false;
},
......@@ -347,13 +347,13 @@
.form-box {
display: flex;
justify-content: space-between;
margin-bottom: 10px;
.num-dv{
display: flex;
align-items: center;
.ml20{
margin-left: 20px;
}
margin-bottom: 10px;
.num-dv{
display: flex;
align-items: center;
.ml20{
margin-left: 20px;
}
}
}
......@@ -367,25 +367,25 @@
margin-right: 10px;
margin-bottom: 10px;
}
}
/deep/.ant-spin-container{
display: block !important;
}
/deep/.ant-drawer-body {
background: #f7f7f7;
padding: 15px;
box-sizing: border-box;
min-height: calc(100vh - 55px);
}
/deep/td {
text-align: left;
}
/deep/.ant-descriptions-item-label{
color: #1890ff;
}
/deep/.ant-spin-container{
display: block !important;
}
/deep/.ant-drawer-body {
background: #f7f7f7;
padding: 15px;
box-sizing: border-box;
min-height: calc(100vh - 55px);
}
/deep/td {
text-align: left;
}
/deep/.ant-descriptions-item-label{
color: #1890ff;
}
.btn-dv {
......
......@@ -79,28 +79,28 @@
v-if="text.status == 0"
color="#108ee9"
>
未签到
{{statusItem[text.status]}}
</a-tag>
<a-tag
@click="openDetails(text.id)"
v-else-if="text.status == 1"
color="#2db7f5"
>
排队中
{{statusItem[text.status]}}
</a-tag>
<a-tag
@click="openDetails(text.id)"
v-else-if="text.status == 2"
color="#f50"
>
超时未取号
{{statusItem[text.status]}}
</a-tag>
<a-tag
@click="openDetails(text.id)"
v-else-if="text.status == 3"
color="red"
>
已取消
{{statusItem[text.status]}}
</a-tag>
</template>
</a-table>
......
......@@ -45,14 +45,14 @@
<div class="infoBox">
<span class="infoTitle imgBox">身份证人像面:</span>
<span class="infoContent">
<img v-if="userInfo.z_img" :src="userInfo.z_img" />
<thumbImage v-if="userInfo.z_img" :src="imgBase+'/'+userInfo.z_img" fileType="img" />
<span v-else>--</span>
</span>
</div>
<div class="infoBox">
<span class="infoTitle imgBox">身份证国徽面:</span>
<span class="infoContent">
<img v-if="userInfo.b_img" :src="userInfo.z_img" />
<thumbImage v-if="userInfo.b_img" :src="imgBase+'/'+userInfo.b_img" fileType="img" />
<span v-else>--</span>
</span>
</div>
......@@ -92,8 +92,17 @@
</template>
<script>
import thumbImage from "@/components/image/thumbImage.vue"
export default {
name: "FormDetails",
components:{
thumbImage
},
data(){
return{
imgBase:process.env.VUE_APP_API_PHP_URL
}
},
props: {
visible: {
type: Boolean,
......
......@@ -161,7 +161,7 @@ export default {
{
title: "是否实名认证",
align: "center",
customRender: (text) => "--",
customRender: (text) => text.idcard_IDCardNo?"实名认证":"未实名认证",
// customRender: (text) => text.create_time || "--",
},
{
......
......@@ -48,6 +48,7 @@
<img v-for="(item,index) in fromData.url" :key="index"
:src="process.env.VUE_APP_API_BASE_URL+item">
</div>
<div v-else>--</div>
</div>
<div class="infoDetail">
<div class="card">
......@@ -81,7 +82,7 @@
<div class="cardTitle">
回复内容<span>(必填)</span>
</div>
<div class="cardContent"></div>
<div class="cardContent">{{ fromData.recontent }}</div>
</div>
</div>
</div>
......@@ -90,9 +91,9 @@
position: 'absolute', right: 0, bottom: 0, width: '100%', borderTop: '1px solid #e9e9e9',
padding: '10px 16px', background: '#fff', textAlign: 'right', zIndex: 1,
}">
<a-button type="primary" @click="onClose">
<!-- <a-button type="primary" @click="onClose">
确定
</a-button>
</a-button> -->
<a-button :style="{ marginRight: '8px' }" @click="onClose">
取消
</a-button>
......
......@@ -2,7 +2,7 @@
<div class="callRecord-Container">
<div class="header_box">
<div>
<a-button type="success" @click="toexportTable">
<a-button type="success" @click="handleExportTable" :loading="btnLoading">
<span>{{ tableSelectedRows.length ? "导出" : "导出全部" }}</span>
</a-button>
<b>建议次数:<i>{{JYCount}}</i></b>
......@@ -57,8 +57,38 @@
<script>
import table from "@/mixins/table";
import FormDetails from "./components/FormDetails.vue";
import {getWLLZList,getWLLZCount,getWLLZInfo} from "@/api/dataAdmin"
import {export2Excel} from "@/utils/js/exportExcel";
const tHeader = [
// 导出的表头名信息
"建议标题",
"建议类型",
"真实姓名",
"联系电话",
"是否公开",
"是否保密",
"提交日期",
"是否回复",
"回复人",
"回复时间",
"所属部门",
]
const filterVal = [
// 导出的表头字段名,需要导出表格字段名
"title",
"type",
"upname",
"upphone",
"valid",
"secrecy",
"create_time",
"status",
"reply_name",
"update_time",
"deptName",
]
export default {
mixins: [table],
name: "networkForm",
......@@ -139,7 +169,7 @@ export default {
{
title: "所属部门",
align: "center",
dataIndex: "dateName",
dataIndex: "deptName",
},
{
title: "操作",
......@@ -159,6 +189,7 @@ export default {
timeList:[],// 时间
JYCount:0,//建议次数
HFCount:0,//回复次数
btnLoading: false,
};
},
components: {
......@@ -186,66 +217,64 @@ export default {
this.isReply = false
this.togetWLLZCount()
},
// 重写导出
toexportTable() {
let tableData = [];
if (this.tableSelectedRows.length == 0) {
getWLLZList({
page:1,
size:-1,
status:this.isReply?0:"",
type:this.nowType,
device:this.nowDevice,
keyword:this.searchName,
time:this.timeList,
}).then((res)=>{
const {code,data} = res;
if(code==1){
// 改变输出内容
data.data.forEach(item => {
item.type = item.type==1?'部门建议':item.type==2?'办事建议':item.type==3?'网站建议':item.type==4?'我要就错':item.type==5?'我要投诉':'我要咨询';
item.valid = item.valid==1?'':'';
item.secrecy = item.secrecy==1?'':'';
item.status = item.status==1?'':'';
});
tableData = JSON.parse(JSON.stringify(data.data));
let tableColumns = JSON.parse(JSON.stringify(this.tableHeaders));
let newTableData = tableData.map(item => {
let obj = {};
for (let key in item) {
obj[key] = item[key];
}
return obj;
})
let exprotExcelName = `${this.nowDay} / ${this.nowTime} / ${this.$route['meta']['title'] || '报表信息统计'}`;
this.exportExcel(tableColumns, newTableData, exprotExcelName);
}
})
} else {
tableData = JSON.parse(JSON.stringify(this.tableSelectedRows));
tableData.forEach(item => {
item.type = item.type==1?'部门建议':item.type==2?'办事建议':item.type==3?'网站建议':item.type==4?'我要就错':item.type==5?'我要投诉':'我要咨询';
item.valid = item.valid==1?'':'';
item.secrecy = item.secrecy==1?'':'';
item.status = item.status==1?'':'';
});
let tableColumns = JSON.parse(JSON.stringify(this.tableHeaders));
let newTableData = tableData.map(item => {
let obj = {};
for (let key in item) {
obj[key] = item[key];
}
return obj;
})
let exprotExcelName = `${this.nowDay} / ${this.nowTime} / ${this.$route['meta']['title'] || '报表信息统计'}`;
this.exportExcel(tableColumns, newTableData, exprotExcelName);
}
},
// 导出
async handleExportTable() {
this.btnLoading = true;
let obj = {
1: "部门建议",
2: "办事建议",
3: "网站建议",
4: "我要就错",
5: "我要投诉",
6: "我要咨询",
};
let data = [];
if (this.tableSelectedKeys.length && this.tableSelectedRows.length) {
// 深度克隆避免影响页面表格展示
data = this.$_.cloneDeep(this.tableSelectedRows);
data.forEach((item) => {
Object.keys(obj).forEach((keys) => {
if (item.type == keys) {
item.type = obj[keys];
}
});
item.valid == 1?item.valid = "":item.valid = ''
item.secrecy == 1?item.secrecy = "":item.secrecy = ''
item.status == 1?item.status = "":item.status = ''
});
} else {
let datas = this.$_.cloneDeep(
await getWLLZList({
page: 1,
size: -1,
status:this.isReply?0:"",
type:this.nowType,
device:this.nowDevice,
keyword:this.searchName,
time:this.timeList,
})
);
data = datas.data.data
if (!data.length) return;
for (let item of data) {
Object.keys(obj).forEach((key) => {
if (item.type == key) {
item.type = obj[key];
}
});
item.valid == 1?item.valid = "":item.valid = ''
item.secrecy == 1?item.secrecy = "":item.secrecy = ''
item.status == 1?item.status = "":item.status = ''
}
}
export2Excel(
tHeader,
filterVal,
data,
"网络理政报表" + this.$moment().format("YYYYMMDDHHmmss")
);
this.btnLoading = false;
},
changeReply(e){
this.isReply = e.target.checked
},
......@@ -294,7 +323,6 @@ export default {
time:this.timeList,
}
getWLLZList(params).then((res)=>{
console.log(res);
const {code,data} = res;
if(code==1){
this.tableSourceData = data.data
......
This diff is collapsed.
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