<template>
|
<div class="selectMenu">
|
<el-form ref="SearchForm" :inline="true" :model="searchData" class="form-inline">
|
<el-form-item label="对账日期" prop="checkDate">
|
<el-date-picker
|
v-model="searchData.checkDate"
|
type="date"
|
placeholder="选择日期"
|
format="yyyy - MM - dd "
|
value-format="yyyy-MM-dd"
|
style="width: 197px;"
|
></el-date-picker>
|
</el-form-item>
|
<el-form-item label="接入机构" prop="institutionId">
|
<el-select v-model="searchData.institutionId" placeholder="请选择" clearable>
|
<el-option
|
v-for="item in institutionArr"
|
:key="item.institutionId"
|
:label="item.institution"
|
:value="item.institutionId"
|
></el-option>
|
</el-select>
|
</el-form-item>
|
<el-form-item label="支付公司" prop="companyId">
|
<el-select v-model="searchData.companyId" placeholder="请选择" clearable>
|
<el-option
|
v-for="item in companyArr"
|
:key="item.companyId"
|
:label="item.payCompany"
|
:value="item.companyId"
|
></el-option>
|
</el-select>
|
</el-form-item>
|
<el-form-item label="订单号" prop="transNo">
|
<el-input v-model="searchData.transNo" placeholder="请输入订单号" style="width: 197px;"></el-input>
|
</el-form-item>
|
<el-form-item label="交易类型" prop="transType">
|
<el-select v-model="searchData.transType" placeholder="请选择" clearable>
|
<el-option v-for="item in transType" :key="item.id" :label="item.value" v-model="item.id"></el-option>
|
</el-select>
|
</el-form-item>
|
<el-form-item label="对账结果" prop="checkResult">
|
<el-select v-model="searchData.checkResult" placeholder="请选择" clearable>
|
<el-option v-for="item in result" :key="item.id" :label="item.value" v-model="item.id"></el-option>
|
</el-select>
|
</el-form-item>
|
<el-form-item label="商户号" prop="merId">
|
<el-input v-model="searchData.merId" placeholder="请输入订单号" style="width: 197px;"></el-input>
|
</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">
|
<div class="btn">
|
<el-button @click="goback">返回</el-button>
|
</div>
|
<el-table :data="menuItems" v-loading="loading" class="table">
|
<el-table-column prop="checkDate" min-width="80" align="center" label="对账日期"></el-table-column>
|
<el-table-column prop="transNo" align="center" min-width="160" label="请求订单号"></el-table-column>
|
<el-table-column prop="transSn" align="center" min-width="200" label="支付订单号"></el-table-column>
|
<el-table-column prop="amount" align="center" min-width="100" label="子订单金额"></el-table-column>
|
<el-table-column prop="transType" align="center" min-width="60" label="交易类型">
|
<template slot-scope="scope">
|
<span>{{enumerMap(scope.row.transType,'transType')}}</span>
|
</template>
|
</el-table-column>
|
<el-table-column prop="payCompany" align="center" min-width="80" label="支付公司"></el-table-column>
|
<el-table-column prop="merId" align="center" min-width="120" label="商户号"></el-table-column>
|
<el-table-column prop="status" align="center" min-width="80" label="支付状态">
|
<template slot-scope="scope">
|
<span>{{enumerMap(scope.row.status,'orderStatus')}}</span>
|
</template>
|
</el-table-column>
|
<el-table-column prop="billAmount" align="center" min-width="100" label="对账单金额"></el-table-column>
|
<el-table-column prop="billFee" align="center" min-width="80" label="对账单手续费"></el-table-column>
|
<el-table-column prop="checkResult" align="center" min-width="100" label="对账结果">
|
<template slot-scope="scope">
|
<span>{{enumerMap(scope.row.checkResult,'checkResult')}}</span>
|
</template>
|
</el-table-column>
|
</el-table>
|
<el-pagination @current-change="handleCurrentChange"
|
:current-page="searchData.page * 1"
|
layout="total, prev, pager,next, jumper"
|
:total.sync="totalCount"
|
:page-size="searchData.pageSize"
|
background
|
style="margin-top: 10px;">
|
</el-pagination>
|
</div>
|
</div>
|
</template>
|
|
<script>
|
import { Message } from "element-ui";
|
export default {
|
data() {
|
return {
|
values: [],
|
menuItems: [],
|
searchData: {
|
// checkDate: "",
|
// institutionId: "",
|
// companyId: "",
|
// transNo: "",
|
// transType: "",
|
// checkResult: "",
|
// merId: "",
|
page: 1,
|
pageSize: 10
|
},
|
tableData: [],
|
institutionArr: [],
|
companyArr: [],
|
loading: false,
|
transType: [
|
{ value: "代付", id: "0" },
|
{ value: "代收", id: "1" },
|
{ value: "退款", id: "2" }
|
],
|
result: [
|
{ value: "平账", id: "01" },
|
{ value: "金额错误", id: "02" },
|
{ value: "我有他无", id: "03" },
|
{ value: "我无他有", id: "04" }
|
],
|
totalCount: 0,
|
checkBatchNo: null
|
};
|
},
|
|
created() {
|
this.checkBatchNo = this.$route.params.data.checkBatchNo
|
this.getAllData();
|
// this.getParamsData();
|
this.getDetailData()
|
},
|
methods: {
|
// 取消按钮
|
goback() {
|
this.$router.replace({
|
path: "/transBalance",
|
name: "TransBalance"
|
});
|
},
|
// 搜索
|
search() {
|
this.$route.params.data = null;
|
this.getDetailData(this.searchData);
|
},
|
// 重置
|
reset() {
|
this.$refs['SearchForm'].resetFields()
|
},
|
// 获取参数
|
getParamsData() {
|
if (this.$route.params.data) {
|
this.tableData = this.$route.params.table;
|
this.getDetailData(this.$route.params.data);
|
} else {
|
this.getDetailData(this.searchData);
|
}
|
},
|
// 获取详情数据
|
getDetailData() {
|
const data = this.searchData
|
const that = this;
|
this.loading = true
|
this.$http
|
.post("check/getCheckBillDetail", {...data, checkBatchNo: this.checkBatchNo})
|
.then(response => {
|
if (response.data.retHeader.retCode === "0000") {
|
if (response.data.retBody.totalCount) {
|
that.totalCount = response.data.retBody.totalCount;
|
}
|
that.menuItems = response.data.retBody.list;
|
this.searchData.queryFlag = 1
|
} else {
|
that.totalCount = 0
|
that.menuItems = []
|
this.$message.error(response.data.retHeader.retMessage)
|
}
|
that.loading = false;
|
})
|
.catch(err => {
|
console.log(err);
|
});
|
},
|
// 获取机构数据
|
getInstitutionsData() {
|
return this.$http.get("manage/getInstitutions");
|
},
|
// 获取公司数据
|
getCompanyData() {
|
return this.$http.get("manage/getCompanys");
|
},
|
// axios并发请求
|
getAllData() {
|
const that = this;
|
this.Axios.all([this.getInstitutionsData(), this.getCompanyData()])
|
.then(
|
this.Axios.spread(function (Institutions, Company) {
|
that.companyArr = Company.data;
|
that.institutionArr = Institutions.data;
|
})
|
)
|
.catch(err => {
|
console.log(err);
|
});
|
},
|
// 点积分页
|
handleCurrentChange(val) {
|
this.searchData.page = val;
|
// if (this.$route.params.data) {
|
// this.searchData.merId = this.$route.params.data.merId;
|
// this.searchData.companyId = this.$route.params.data.companyId;
|
// this.searchData.institutionId = this.$route.params.data.institutionId;
|
// this.searchData.checkDate = this.$route.params.data.checkDate;
|
// }
|
this.getDetailData(this.searchData);
|
}
|
}
|
};
|
</script>
|
|
<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 {
|
color: blue;
|
font-size: 14px;
|
}
|
}
|
}
|
}
|
.selectMenu {
|
width: 100%;
|
margin: 0px auto;
|
padding: 0px 10px;
|
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 {
|
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;
|
color: white;
|
font-size: 14px;
|
width: 12.5%;
|
margin-right: -1px;
|
}
|
}
|
.add {
|
margin: 10px 0px 5px;
|
}
|
.channelMenuContent {
|
width: 100%;
|
.contentItem {
|
width: 100%;
|
height: 36px;
|
> .contentValue {
|
float: left;
|
width: 12.5%;
|
height: 36px;
|
border: 1px solid #797979;
|
border-top: none;
|
text-align: center;
|
line-height: 36px;
|
background-color: #fff;
|
margin-right: -1px;
|
> button {
|
border: 1px solid #eee;
|
background-color: #66b1ff;
|
width: 50px;
|
height: 70%;
|
border-radius: 6px;
|
outline: none;
|
}
|
}
|
}
|
}
|
}
|
.btn {
|
width: 70px;
|
padding: 10px 0px;
|
margin-top: 20px;
|
}
|
}
|
</style>
|