<template>
|
<div class="menuPage">
|
<div class="selectMenu">
|
<el-form :inline="true" :model="searchData" class="form-inline">
|
<el-form-item label="客户名称">
|
<el-input v-model="searchData.acctName" placeholder="请输入客户名称" style="width: 197px;" clearable></el-input>
|
</el-form-item>
|
<el-form-item label="手机号">
|
<el-input v-model="searchData.phone" placeholder="请输入手机号" style="width: 197px;" clearable></el-input>
|
</el-form-item>
|
<el-form-item label="银行卡号">
|
<el-input v-model="searchData.acctNo" placeholder="请输入银行卡号" style="width: 197px;" clearable></el-input>
|
</el-form-item>
|
<el-form-item label="签约状态">
|
<el-select v-model="searchData.treatyStatus" placeholder="请选择" style="width: 197px;" clearable>
|
<el-option
|
v-for="(item,index) in statusList"
|
:key=index
|
:label="item.key"
|
:value="item.value"
|
></el-option>
|
</el-select>
|
</el-form-item>
|
<el-form-item class="search">
|
<el-button @click="search" type="primary">查询</el-button>
|
<el-button @click="reset">重置</el-button>
|
</el-form-item>
|
</el-form>
|
<div class="channelMenu">
|
<el-table :data="menuItems" v-loading="loading" class="table">
|
<el-table-column prop="acctName" align="center" min-width="140" label="客户名称"></el-table-column>
|
<el-table-column prop="phone" align="center" min-width="140" label="手机号码"></el-table-column>
|
<el-table-column prop="bankName" align="center" min-width="200" label="银行名称"></el-table-column>
|
<el-table-column prop="acctNo" align="center" min-width="200" label="银行卡号"></el-table-column>
|
<el-table-column prop="idNos" align="center" min-width="200" label="身份证"></el-table-column>
|
<el-table-column prop="submitTime" align="center" min-width="200" label="扣款交易时间"></el-table-column>
|
<el-table-column prop="status" align="center" min-width="100" label="扣款状态">
|
<template slot-scope="scope">
|
<span>{{enumerMap(scope.row.status,'transStatus')}}</span>
|
</template>
|
</el-table-column>
|
<el-table-column prop="status" align="center" min-width="100" label="协议签约">
|
<template slot-scope="scope">
|
<span>{{enumerMap(scope.row.treatyStatus,'treatyStatus')}}</span>
|
</template>
|
</el-table-column>
|
<el-table-column prop="notifyTime" align="center" min-width="200" label="最近提醒时间"></el-table-column>
|
<el-table-column prop="notifyDays" align="center" min-width="150" label="最近提醒天数"></el-table-column>
|
<el-table-column fixed="right" align="center" min-width="150" label="操作">
|
<template slot-scope="scope">
|
<el-button size="mini" type="primary" @click="notify(scope.row)">短信通知</el-button>
|
</template>
|
</el-table-column>
|
</el-table>
|
</div>
|
<el-pagination
|
layout="total, prev, pager, next, jumper"
|
:total.sync="totalCount"
|
:current-page="searchData.page * 1"
|
background
|
ref="pagination"
|
style="margin-top: 10px;"
|
@current-change="handleCurrentChange"
|
></el-pagination>
|
</div>
|
<my-mask v-model="showMask"
|
:data="maskData"
|
v-on:isShowMask="hideMask"></my-mask>
|
</div>
|
</template>
|
|
<script>
|
import { mapGetters } from "vuex";
|
import MyMask from "./Mask";
|
|
export default {
|
data() {
|
return {
|
showMask: false,
|
maskData: {},
|
menuItems: [],
|
searchData: {
|
page: "1",
|
pageSize: "10",
|
acctNo: null,
|
acctName: null,
|
phone: null,
|
treatyStatus: null,
|
queryFlag: 0
|
},
|
statusList: [
|
{ value: "0", key: "否" },
|
{ value: "1", key: "是" }
|
],
|
loading: false,
|
totalCount: 0,
|
rules: {
|
}
|
};
|
},
|
components: {
|
MyMask
|
},
|
created() {
|
this.getMenuData();
|
},
|
computed: {
|
...mapGetters(["getMenu"])
|
},
|
watch: {
|
getMenu: function (now, old) {
|
this.getMenuData();
|
}
|
},
|
methods: {
|
// 获取表单数据
|
getMenuData() {
|
const that = this;
|
this.loading = true;
|
this.$http
|
.post("treaty/query", this.searchData)
|
.then(Menu => {
|
if (Menu.data.retHeader.retCode === "0000") {
|
if (Menu.data.retBody.totalCount) {
|
that.totalCount = Menu.data.retBody.totalCount;
|
}
|
that.menuItems = Menu.data.retBody.list;
|
this.encrypt(that.menuItems)
|
this.searchData.queryFlag = 1
|
} else {
|
that.totalCount = 0
|
that.menuItems = []
|
this.$message.error(Menu.data.retHeader.retMessage)
|
}
|
this.loading = false;
|
})
|
.catch(err => {
|
console.log(err);
|
});
|
},
|
// 查询
|
search() {
|
this.searchData.page = 1
|
this.searchData.queryFlag = 0
|
this.getMenuData();
|
},
|
// 重置
|
reset() {
|
this.searchData = {
|
acctNo: null,
|
acctName: null,
|
phone: null,
|
treatyStatus: null,
|
page: "1",
|
pageSize: "10",
|
queryFlag: 0
|
};
|
this.getMenuData()
|
},
|
// 分页
|
handleCurrentChange(val) {
|
this.searchData.page = val;
|
this.getMenuData();
|
},
|
// 身份证显示加密
|
encrypt(arr) {
|
arr.forEach(item => {
|
if (item.idNo) {
|
item.idNos = item.idNo.slice(0, 4) + "**********" + item.idNo.slice(12, 16);
|
}
|
});
|
},
|
// 隐藏弹窗
|
hideMask() {
|
this.handleCurrentChange(1);
|
this.showMask = false;
|
},
|
// 短信通知弹窗
|
notify(row) {
|
this.maskData = row;
|
this.showMask = true;
|
}
|
}
|
};
|
</script>
|
|
<style>
|
.el-input__icon.el-icon-date {
|
display: none;
|
}
|
</style>
|
|
<style lang="less" scoped>
|
table {
|
width: 100%;
|
> tr {
|
width: 100%;
|
&:first-child {
|
> td {
|
background-color: #333333;
|
color: white;
|
}
|
}
|
td {
|
padding: 6px;
|
text-align: center;
|
font-size: 14px;
|
> a {
|
cursor: pointer;
|
}
|
}
|
}
|
}
|
|
.menuPage {
|
width: 100%;
|
padding: 0px 0px;
|
// overflow: hidden;
|
.selectMenu {
|
width: 100%;
|
overflow: hidden;
|
border-radius: 8px;
|
.selectOptions {
|
width: 60%;
|
overflow: hidden;
|
border-bottom: 1px solid #eee;
|
.subMenuItem {
|
width: 50%;
|
float: left;
|
padding: 8px 0px;
|
color: black;
|
> span {
|
display: inline-block;
|
font-size: 14px;
|
width: 26%;
|
height: 100%;
|
text-align: right;
|
}
|
}
|
}
|
.selectBtn {
|
width: 60%;
|
height: 100%;
|
padding: 10px 0px;
|
.center {
|
margin-left: 50%;
|
transform: translateX(-50%);
|
> button {
|
padding: 8px 23px;
|
margin-right: 20px;
|
}
|
}
|
}
|
.channelMenu {
|
width: 100%;
|
margin-top: 20px;
|
.channelMenuTitle {
|
width: 100%;
|
height: 30px;
|
> div {
|
height: 100%;
|
float: left;
|
background-color: #333333;
|
border: 1px solid #999;
|
line-height: 30px;
|
text-align: center;
|
color: white;
|
font-size: 14px;
|
width: 12.5%;
|
margin-right: -1px;
|
}
|
}
|
.add {
|
margin: 10px 0px 5px;
|
}
|
.channelMenuContent {
|
width: 100%;
|
.contentItem {
|
width: 100%;
|
height: 36px;
|
a {
|
font-size: 12px;
|
color: blue;
|
outline: none;
|
}
|
}
|
}
|
}
|
}
|
}
|
</style>
|