Commit 3312433b by WF1020

修改infgid的详情与处理

parent 5d8297a9
import Api from '~/service/Api';
import { getTrnNameByInr } from "~/service/business/common";
export default {
methods: {
async handleSearch() {
......@@ -21,13 +22,13 @@ export default {
cmtflg: this.model.cmtflg,
fingua: this.model.fingua,
pageIndex: this.pagination.pageIndex,
pageSize: this.pagination.pageSize
pageSize: this.pagination.pageSize,
};
let rtnmsg = await Api.post('/service/infgid/getList', params);
if (rtnmsg.respCode == SUCCESS) {
this.stmData.data = [];
this.stmData.data = rtnmsg.data.list;
this.pagination.total = rtnmsg.data.total
this.pagination.total = rtnmsg.data.total;
} else {
this.$notify.error({ title: '错误', message: '服务请求失败!' });
}
......@@ -63,15 +64,61 @@ export default {
// pageSize改变
handleSizeChange(val) {
console.log(`每页 ${val} 条`);
this.pagination.pageIndex = 1
this.pagination.pageSize = val
this.handleSearch()
this.pagination.pageIndex = 1;
this.pagination.pageSize = val;
this.handleSearch();
},
// 页码改变
handleCurrentChange(val) {
console.log(`当前页: ${val}`);
this.pagination.pageIndex = val
this.handleSearch()
this.pagination.pageIndex = val;
this.handleSearch();
},
toGitpop() {
this.$router.history.push('/business/gitpop');
},
toGitopn() {
this.$router.history.push('/business-new/gitopn');
},
toGetopn() {
this.$router.history.push('/business/getopn');
},
// 详情
async details(row) {
const params = {
//根据xx字段 查询详情表的数据
ownref: row.ownref,
};
const res = await Api.post('/service/infgid/getDetailByOwnref', params);
if (res.respCode === SUCCESS) {
this.trnData.data = res.data;
}
},
// 关闭详情弹框
closeDetailsDialog(refId) {
this.$refs[refId].doClose();
console.log('close');
},
// 处理
handler() {
this.initdialog = true;
},
// 关闭处理弹框
closeHandlerDialog() {
this.initdialog = false;
},
/**
* 打开详情页面
* @param {string} inr
*/
display(inr) {
getTrnNameByInr({ inr }).then((res) => {
if (res.respCode == SUCCESS) {
const trnName = res.data.toLowerCase();
let viewurl = "/#/display/" + trnName + "?trn=" + inr
window.open(viewurl, 'newwindow', 'height=1500,width=1200,top=100,left=100,toolbar=no,resizable=no,menubar=no,location=no, status=no');
}
});
}
},
};
......@@ -487,34 +487,39 @@
@click="closeDetailsDialog('popover_' + scope.row.IDX)"
></span>
</div>
<c-istream-table
:list="trnData.data"
<el-table
:data="trnData.data"
:columns="trnData.columns"
:showButtonFlg="true"
>
<el-table-column
prop="op"
label="操作"
width="0"
fixed="right"
v-for="(item, key) in trnData.columns"
:key="key"
:label="item.label"
:prop="item.prop"
>
<template slot-scope="scope">
<div>{{ scope.row[item.prop] }}</div>
</template>
</el-table-column>
<el-table-column fixed="right" prop="op" label="操作" width="250px" >
<template slot-scope="scope">
<c-button
style="margin-left: 0"
size="small"
@click="display(scope.row['INR'])"
@click="display(scope.row['inr'])"
>详情</c-button
>
</template>
</el-table-column>
</c-istream-table>
</el-table>
<c-button
style="margin-left: 0"
size="small"
slot="reference"
@click="details"
>
详情</c-button
>
@click="details(scope.row)">
详情
</c-button>
</el-popover>
<c-button
style="margin-left: 5px"
......@@ -553,7 +558,7 @@
:key="index"
type="primary"
:disabled="item.disabled"
></el-button>
>{{ item.name }}</el-button>
</div>
</el-dialog>
</div>
......@@ -572,7 +577,7 @@ export default {
// 表格相关
stmData: {
columns: [
{
{
label: '保函编号',
prop: 'ownref'
},
......@@ -607,21 +612,38 @@ export default {
// 详情
trnData: {
columns: [
'0 1 "交易ID" 100',
'1 2 "保函编号" 200',
'2 3 "交易名称" 200',
'3 4 "条目" 200',
{
index: 4,
position: 5,
width: 100,
pattern: "code",
label: "状态",
code: this.codes.relflg,
label: '交易id',
prop: 'inr'
},
{
label: '保函编号',
prop: 'ownref'
},
{
label: '交易名称',
prop: 'ininam'
},
{
label: '条目',
prop: 'inidattim'
},
{
label: '状态',
prop: 'relflg'
},
{
label: '币种',
prop: 'reloricur'
},
{
label: '相关金额',
prop: 'reloriamt'
},
{
label: '标识',
prop: 'relres'
},
'5 6 "币种" 80',
'6 7 "相关金额" 150',
'7 8 "标识" 100',
],
data: [],
},
......@@ -631,32 +653,7 @@ export default {
};
},
methods: {
toGitpop() {
this.$router.history.push("/business/gitpop");
},
toGitopn() {
this.$router.history.push("/business-new/gitopn");
},
toGetopn() {
this.$router.history.push("/business/getopn");
},
// 详情
async details(idx, row) {
},
// 关闭详情弹框
closeDetailsDialog(refId) {
this.$refs[refId].doClose();
console.log('close')
},
// 处理
handler () {
this.initdialog = true
},
// 关闭处理弹框
closeHandlerDialog () {
this.initdialog = false
}
},
mounted () {},
};
......
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