Commit 541bd934 by 李少勇

smtsel 交易增加导出功能

parent 82471bdd
import Api from "~/service/Api";
import Smtsel from "../model";
import Utils from "~/utils";
import exportExcel from '~/page/Frontend/Rcvsel/event/exportExcel.js';
export default {
mixins: [],
mixins: [exportExcel],
methods: {
async handleSearch() {
this.load = true;
let rtnmsg = await Api.post("/frontend/smtsel", {
...this.model,
pageNumber: this.pagenation.pageNum,
let rtnmsg = await Api.post("/frontend/smtsel/query", {
...this.model.smtp,
pageNum: this.pagenation.pageNum,
pageSize: this.pagenation.pageSize,
});
if (rtnmsg.respCode == SUCCESS) {
......@@ -42,5 +43,72 @@ export default {
this.pagenation.pageNum = val;
this.handleSearch();
},
exportToExcel() {
let codeKeysMap = {
typ: 'kpatyp'
};
let params = {
...this.model.smtp,
}
let columns = [
{
label: "收报日期",
prop: "recdat",
},
{
label: "起息日期",
prop: "valdat",
},
{
label: "账户行名称",
prop: "chnnam",
},
{
label: "BIC",
prop: "bic",
},
{
label: "帐号",
prop: "acc",
},
{
label: "币种",
prop: "cur",
},
{
label: "对账单参考号",
prop: "ref",
},
{
label: "单编号",
prop: "smtno",
},
{
label: "期初金额",
prop: "begamt",
},
{
label: "期末金额",
prop: "endamt",
},
{
label: "期末可用金额",
prop: "endvalamt",
},
{
label: "对账单类型",
prop: "typ",
},
{
label: "页数",
prop: "pag",
},
{
label: "明细条数",
prop: "dtl",
},
]
this.exportExcel(columns, '/frontend/smtsel/exportExcel', params, codeKeysMap, '对账单查询');
}
}
}
\ No newline at end of file
......@@ -29,7 +29,6 @@ export default class Smtsel {
lst: [], // .smtgrp.smtsub.lst
},
},
pageId: "" // ctx的key
}
}
}
\ No newline at end of file
......@@ -97,7 +97,7 @@
<el-col :span="24" style="margin-left: 0px">
<c-button class="medium_bcs" style="margin-left: 20" size="medium" type="primary"
@click="batchupdateAck">导出</c-button>
@click="exportToExcel">导出</c-button>
</el-col>
<el-col :span="24" style="margin-top: 10px">
......@@ -135,6 +135,9 @@
</template>
</el-table-column>
<el-table-column prop="typ" label="对账单类型" width="150">
<template slot-scope="scope">
<c-select-value-to-label v-model="scope.row.typ" dbCode="KPATYP"></c-select-value-to-label>
</template>
</el-table-column>
<el-table-column prop="pag" label="页数" width="100">
</el-table-column>
......@@ -204,9 +207,6 @@ export default {
updateAck(row) {
},
batchupdateAck() {
},
async currentchange(num) {
this.pagination.pageNum = num;
this.formsubmit();
......
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