Commit 33482d1d by WH

feat:inftrd

parent 0e08d382
import Api from '~/service/Api';
import { getTrnNameByInr } from "~/service/business/common";
import moment from 'moment';
export default {
methods: {
async handleSearch() {
let opndatfrom = this.model.infcon.opndatfrom;
if (!opndatfrom || opndatfrom == '') {
this.$notify.error({ title: '错误', message: '查询开始日期必输!' });
return;
}
let opndatto = this.model.infcon.opndatto;
if (!opndatto || opndatto == '') {
this.$notify.error({ title: '错误', message: '查询结束日期必输!' });
return;
}
let params = {
...this.model.infcon,
// seadocflg: this.model.seadocflg,
// seagodcod: this.model.seagodcod,
inr:this.model.trdgrp.rec.inr,
pageIndex: this.pagination.pageIndex,
pageSize: this.pagination.pageSize,
opndatfrom:moment(opndatfrom).format('YYYY-MM-DD'),
opndatto:moment(opndatto).format('YYYY-MM-DD'),
};
let rtnmsg = await Api.post('/service/inftrd/getList', params);
if (rtnmsg.respCode == SUCCESS) {
this.stmData.data = [];
this.stmData.data = rtnmsg.data.list;
// debugger
this.pagination.total = rtnmsg.data.total;
} else {
this.$notify.error({ title: '错误', message: '服务请求失败!' });
}
},
async handleReset() {
this.model.infcon.chksubcon = '';
this.model.infcon.opndatfrom = new Date();
this.model.infcon.opndatto = new Date();
this.model.infcon.seaownref = '';
this.model.infcon.seashgref = '';
this.model.infcon.seaamtfr = '';
this.model.infcon.seasta = '';
this.model.infcon.seacur = '';
this.model.infcon.pty.extkey = '';
this.model.infcon.pty.nam = '';
this.model.infcon.usr.extkey = '';
this.model.infcon.objinr = '';
this.model.infcon.seaamtto = '';
this.model.infcon.searol = '';
this.model.infcon.nam = '';
this.model.infcon.seapty = '';
this.model.infcon.searef = '';
this.model.trdgrp.rec.inr = '';
// this.model.seagodcod = '';
// this.model.seadocflg = '';
},
// pageSize改变
handleSizeChange(val) {
console.log(`每页 ${val} 条`);
this.pagination.pageIndex = 1;
this.pagination.pageSize = val;
this.handleSearch();
},
// 页码改变
handleCurrentChange(val) {
console.log(`当前页: ${val}`);
this.pagination.pageIndex = val;
this.handleSearch();
},
// 详情
async details(row) {
const params = {
//根据xx字段 查询详情表的数据
inr:row.inr,
userId: window.sessionStorage.userId || 'ZL',
ownref: row.ownref,
};
const res = await Api.post('/service/inftrd/getDetail', params);
if (res.respCode === SUCCESS) {
this.trnData.data = res.data;
}
},
// 关闭详情弹框
closeDetailsDialog(refId) {
this.$refs[refId].doClose();
console.log('close');
},
// 处理
async handler(row) {
this.initdialog = true;
this.currentHandleRow = row
const params = {
//根据xx字段 查询处理的数据
seaownref: row.seaownref,
};
const res = await Api.post('/service/inftrd/dealWithByOwnref', params);
if (res.respCode === SUCCESS) {
if (res.data) {
this.handlerDataList = []
Object.keys(res.data).map((item) => {
this.handlerDataList.push({
label: item,
value: res.data[item]
})
})
}
}
},
handleClick (btn) {
if (btn.value === 'N') {
return
}
let filterRoute = this.btnRouteMap.filter((item) => {
return item.label === btn.label
})
this.$router.history.push({
path: filterRoute[0].route,
query: {
inr: this.currentHandleRow.inr
}
});
this.initdialog = false;
},
// 关闭处理弹框
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');
}
});
},
},
};
import Pts from '~/components/business/commonModel/Pts';
import Pub from '~/components/business/commonModel/index.js';
export default class Inftrd {
constructor() {
this.data = {
seafintyp: '',
trdgrp: {
rec: {
stagod: '',
inr: '',
oseflg: ''
}
},
infcon: {
chksubcon: '',
opndatfrom: '',
opndatto: '',
seaownref: '',
seaamtfr: '',
seasta: '',
seacur: '',
pty: {
extkey: '',
nam: ''
},
cxmflg: '',
usr: {
extkey: ''
},
objinr: '',
seaamtto: '',
searol: '',
nam: '',
seapty: '',
searef: ''
}
};
}
}
<template>
<div class="eContainer-search">
<el-form :model="model" :rules="rules" ref="modelForm" label-width="120px" label-position="right" size="small"
:validate-on-rule-change="false">
<c-content>
<m-infsea
v-show="!showPanel"
:model="model"
:codes="codes"
ref="infsea"/>
</c-content>
<c-button
v-show="showPanel"
style="margin-left: 75%; bottom: 10%; position: sticky"
size="small"
@click="goBack()">
返回
</c-button>
</el-form>
</div>
</template>
<script>
import CodeTable from "~/config/CodeTable"
import Inftrd from "../model"
import Infsea from "./Infsea"
export default {
name: "Inftrd",
components: {
"m-infsea": Infsea,
},
provide() {
return {
root: this
}
},
data() {
return {
tabVal: "infsea",
trnName: "inftrd",
trnType: "",
model: new Inftrd().data,
showPanel: false,
codes: {...CodeTable},
rules: null,
}
},
methods: {},
initPanel(val) {
if (val) {
this.tabVal = "infsea";
//
} else {
this.tabVal = "";
}
},
async updateShowPanel(value) {
this.showPanel = value;
this.initPanel(value);
},
goBack() {
this.showPanel = false;
},
}
</script>
<style>
</style>
......@@ -95,6 +95,7 @@ const Business = [
{ path: 'cctset', component: () => import('~/business/cctset/views'), name: 'Cctset', meta: { title: '光票托收结汇' }},
{ path: 'cctdcr', component: () => import('~/business/cctdcr/views'), name: 'Cctdcr', meta: { title: '光票托收退票' }},
{ path: 'infcld', component: () => import('~/business/infcld/views'), name: 'Infcld', meta: { title: '打包托收查询' }},
{ path: 'inftrd', component: () => import('~/business/inftrd/views'), name: 'Inftrd', meta: { title: '进口融资查询' }},
]
export default Business
\ No newline at end of file
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