Commit 40dbc8d3 by chengzhuoshen

外币兑换平盘登记fxtfop前端初始页面

parent 501a25c9
...@@ -13,7 +13,7 @@ const BusRouter = [ ...@@ -13,7 +13,7 @@ const BusRouter = [
// { path: 'fxteqo', component: ()=>import("./Fxteqo/views"), name: 'Fxteqo', meta: { title: 'Fxteqo' } ,module:'Funds'}, // { path: 'fxteqo', component: ()=>import("./Fxteqo/views"), name: 'Fxteqo', meta: { title: 'Fxteqo' } ,module:'Funds'},
// { path: 'fxtfcm', component: ()=>import("./Fxtfcm/views"), name: 'Fxtfcm', meta: { title: 'Fxtfcm' } ,module:'Funds'}, // { path: 'fxtfcm', component: ()=>import("./Fxtfcm/views"), name: 'Fxtfcm', meta: { title: 'Fxtfcm' } ,module:'Funds'},
// { path: 'fxtfcn', component: ()=>import("./Fxtfcn/views"), name: 'Fxtfcn', meta: { title: 'Fxtfcn' } ,module:'Funds'}, // { path: 'fxtfcn', component: ()=>import("./Fxtfcn/views"), name: 'Fxtfcn', meta: { title: 'Fxtfcn' } ,module:'Funds'},
// { path: 'fxtfop', component: ()=>import("./Fxtfop/views"), name: 'Fxtfop', meta: { title: 'Fxtfop' } ,module:'Funds'}, { path: 'fxtfop', component: ()=>import("./Fxtfop/views"), name: 'fxtfop', meta: { title: '外币兑换平盘登记' } ,module:'Funds'},
// { path: 'fxtlcm', component: ()=>import("./Fxtlcm/views"), name: 'Fxtlcm', meta: { title: 'Fxtlcm' } ,module:'Funds'}, // { path: 'fxtlcm', component: ()=>import("./Fxtlcm/views"), name: 'Fxtlcm', meta: { title: 'Fxtlcm' } ,module:'Funds'},
// { path: 'fxtlcn', component: ()=>import("./Fxtlcn/views"), name: 'Fxtlcn', meta: { title: 'Fxtlcn' } ,module:'Funds'}, // { path: 'fxtlcn', component: ()=>import("./Fxtlcn/views"), name: 'Fxtlcn', meta: { title: 'Fxtlcn' } ,module:'Funds'},
// { path: 'fxtlop', component: ()=>import("./Fxtlop/views"), name: 'Fxtlop', meta: { title: 'Fxtlop' } ,module:'Funds'}, // { path: 'fxtlop', component: ()=>import("./Fxtlop/views"), name: 'Fxtlop', meta: { title: 'Fxtlop' } ,module:'Funds'},
......
import Utils from "~/utils";
export default {
methods: {
buildPtspta(ptsptaObj) {
let pts = ptsptaObj.pts;
return {
rol: pts.rol,
name: pts.nam,
ptyinr: pts.ptyinr,
ptainr: pts.ptainr,
extkey: pts.extkey,
dftdsp: pts.dftdsp,
dftcur: pts.dftcur,
dftact: pts.dftact,
dftfeecur: pts.dftfeecur,
dftactptainr: pts.dftactptainr,
glggrpflg: pts.glggrpflg,
adrblk: pts.adrblk,
pts,
};
},
buildCommonData(model, trnName) {
let ptsptaList = Utils.formatPtspta(model.fxdgrp, this.buildPtspta);
return {
rec: {
objtyp: "FXD",
objinr: model.fxdgrp.rec.inr,
ownref: model.fxdgrp.rec.ownref,
},
cbsMap: {
MAX: model.fxdgrp.cbs.max,
NOM1: model.fxdgrp.cbs.nom1,
},
ptsList: ptsptaList,
transName: trnName,
userId: window.sessionStorage.userId ? window.sessionStorage.userId : "ZL",
};
},
},
};
import commonFunctions from '~/mixin/commonFunctions.js';
import Api from '~/service/Api';
export default {
mixins: [commonFunctions],
methods: {
async getOwnref(){
}
}
}
\ No newline at end of file
import Utils from "~/utils"
/**
* Fxtfop Check规则
*/
let checkObj = {
"fxdgrp.apl.pts.adrblk" :null,
"fxdgrp.rec.rat" :null,
"fxtp.usr.extkey" :null,
"fxdgrp.cbs.max.cur" :null,
"fxdgrp.rec.opndat" :null,
"fxtp.cnychk" :null,
"fxdgrp.rec.valdat" :null,
"fxdgrp.apl.pts.extkey" :null,
}
for (const key in checkObj) {
if (Object.hasOwnProperty.call(checkObj, key)) {
checkObj[key] = checkObj[key] ? checkObj[key] : Utils.reflectCheck(key)
}
}
export default checkObj
/**
* Fxtfop Default规则
*/
import Api from "~/service/Api";
import Utils from "~/utils/index"
export default {
"fxtp.cnychk" :Utils.defaultFunction,
"fxtp.frgchk" :Utils.defaultFunction,
"fxdgrp.apl.dbfadrblkcn" :Utils.defaultFunction,
"fxdgrp.cbs.nom1.cur" :Utils.defaultFunction,
"fxdgrp.cbs.max.cur" :Utils.defaultFunction,
"fxdgrp.rec.fxtyp" :Utils.defaultFunction,
"fxtp.usr.extkey" :Utils.defaultFunction,
"fxdgrp.rec.rat" :Utils.defaultFunction,
"fxdgrp.cbs.nom1.amt" :Utils.defaultFunction,
"fxdgrp.cbs.max.amt" :Utils.defaultFunction,
"fxdgrp.apl.pts.adrblk" :Utils.defaultFunction,
"fxdgrp.apl.pts.extkey" :Utils.defaultFunction,
"fxdgrp.rec.ownref" :Utils.defaultFunction,
"fxdgrp.rec.opndat" :Utils.defaultFunction,
}
//你可以添加自动default处理
import Api from "~/service/Api"
import Utils from "~/utils"
export default {
async onFxtpButgetref(){
let rtnmsg = await this.executeRule("fxtp.butgetref")
if(rtnmsg.respCode == SUCCESS)
{
//TODO 处理数据逻辑
}
else
{
this.$notify.error({title: '错误',message: '服务请求失败!'});
}
},
async onAplpDet(){
let rtnmsg = await this.executeRule("aplp.det")
if(rtnmsg.respCode == SUCCESS)
{
//TODO 处理数据逻辑
}
else
{
this.$notify.error({title: '错误',message: '服务请求失败!'});
}
},
}
\ No newline at end of file
export default {
"fxdgrp.rec.ownref":[
{type: "string", required: false, message: "必输项"},
{max: 16,message:"长度不能超过16"}
],
"fxdgrp.rec.nam":[
{type: "string", required: false, message: "必输项"},
{max: 40,message:"长度不能超过40"}
],
"fxdgrp.apl.pts.ref":[
{type: "string", required: false, message: "必输项"},
{max: 20,message:"长度不能超过20"}
],
"fxtp.usr.extkey":[
{type: "string", required: false, message: "必输项"},
{max: 8,message:"长度不能超过8"}
],
"fxtp.usrget.sdamod.seainf":[
{type: "string", required: false, message: "必输项"},
{max: 3,message:"长度不能超过3"}
],
"fxtp.aplp.ptsget.sdamod.dadsnd":[
{type: "string", required: false, message: "必输项"},
{max: 16,message:"长度不能超过16"}
],
"fxdgrp.apl.pts.extkey":[
{type: "string", required: false, message: "必输项"},
{max: 16,message:"长度不能超过16"}
],
"fxtp.aplp.ptsget.sdamod.seainf":[
{type: "string", required: false, message: "必输项"},
{max: 3,message:"长度不能超过3"}
],
"fxdgrp.apl.pts.adrblk":[
{type: "string", required: true, message: "必输项"},
{max: 35,message:"长度不能超过35"}
],
"fxdgrp.apl.dbfadrblkcn":[
{type: "string", required: true, message: "必输项"},
{max: 35,message:"长度不能超过35"}
],
"fxdgrp.cbs.max.amt":[
{type: "number", required: false, message: "必输项"},
{max: 18,message:"整数位不能超过14位"},
{pattern: /(^\d+$)|(^\.\d{1,3}$)|(^\d+\.\d{1,3}$)/, message: "小数位不能超过3位" }
],
"fxdgrp.cbs.nom1.amt":[
{type: "number", required: false, message: "必输项"},
{max: 18,message:"整数位不能超过14位"},
{pattern: /(^\d+$)|(^\.\d{1,3}$)|(^\d+\.\d{1,3}$)/, message: "小数位不能超过3位" }
],
"fxdgrp.rec.rat":[
{type: "string", required: false, message: "必输项"},
{max: 12,message:"长度不能超过12"}
],
"fxdgrp.rec.midrat":[
{type: "string", required: false, message: "必输项"},
{max: 12,message:"长度不能超过12"}
],
"fxdgrp.rec.opndat":[
{type: "date", required: false, message: "输入正确的日期"}
],
"fxdgrp.rec.valdat":[
{type: "date", required: false, message: "输入正确的日期"}
],
"fxdgrp.blk.remark":[
{type: "string", required: true, message: "必输项"},
{max: 35,message:"长度不能超过35"}
],
}
\ No newline at end of file
import Api from "~/service/Api" import Api from "~/service/Api"
import Pts from "../Common/Pts" import Pts from "~/page/Model/Common/Pts"
import Pub from "../../../../components/business/commonModel/index.js";
export default class Fxtfop{ export default class Fxtfop{
constructor () { constructor () {
this.data = { this.data = {
fxdgrp:{ fxdgrp:{
rec:{ rec:{
ownref:"", // 业务编号 .fxdgrp.rec.ownref ownref:"", // 业务编号 .fxdgrp.rec.ownref
nam:"", // 业务名称 .fxdgrp.rec.nam nam:"", // 业务名称 .fxdgrp.rec.nam
fxtyp:"", // 平盘类型 .fxdgrp.rec.fxtyp fxtyp:"", // 平盘类型 .fxdgrp.rec.fxtyp
opndat:"", // 成交日 .fxdgrp.rec.opndat opndat:"", // 成交日 .fxdgrp.rec.opndat
valdat:"", // 起息日 .fxdgrp.rec.valdat valdat:"", // 起息日 .fxdgrp.rec.valdat
rat:"", // 平盘牌价 .fxdgrp.rec.rat rat:"", // 平盘牌价 .fxdgrp.rec.rat
midrat:"", // 中间价 .fxdgrp.rec.midrat midrat:"", // 中间价 .fxdgrp.rec.midrat
}, ownusr:"",
apl:{ },
pts:new Pts().data, apl:{
dbfadrblkcn:"", // Chinese address .fxdgrp.apl.dbfadrblkcn pts:new Pts().data,
}, },
blk:{ blk:{
remark:"", // 备注 .fxdgrp.blk.remark remark:"", // 备注 .fxdgrp.blk.remark
}, },
cbs:{ cbs:{
max:{ max:{
cur:"", // Currency .fxdgrp.cbs.max.cur cur:"", // Currency .fxdgrp.cbs.max.cur
amt:"", // Balance .fxdgrp.cbs.max.amt amt:"", // Balance .fxdgrp.cbs.max.amt
}, },
nom1:{ nom1:{
cur:"", // Currency .fxdgrp.cbs.nom1.cur cur:"", // Currency .fxdgrp.cbs.nom1.cur
amt:"", // Balance .fxdgrp.cbs.nom1.amt amt:"", // Balance .fxdgrp.cbs.nom1.amt
}, },
}, },
}, },
fxtp:{ fxtp:{
amtlab:"", // Amount Label .fxtp.amtlab
cnylab:"", // Amount LabelCNY .fxtp.cnylab },
frgchk:"", // 外币 .fxtp.frgchk setmod: new Pub().data.Setmod,
cnychk:"", // 人民币 .fxtp.cnychk docpan: new Pub().data.Docpan,
aplp:{ trndia: new Pub().data.Trndia,
ptsget:{ }
sdamod:{
seainf:"", // .fxtp.aplp.ptsget.sdamod.seainf
dadsnd:"", // Drag Drop Sender .fxtp.aplp.ptsget.sdamod.dadsnd
},
},
},
usrget:{
sdamod:{
seainf:"", // .fxtp.usrget.sdamod.seainf
},
},
usr:{
extkey:"", // 业务负责人 .fxtp.usr.extkey
},
},
pageId: "" // ctx的key
}
} }
} }
\ No newline at end of file
<template> <template>
<div class="eContainer"> <div class="eContainer">
<c-page title="外币兑换平盘登记">
<el-form :model="model" :rules="rules" ref="modelForm" label-width="150px" label-position="right" size="small" :validate-on-rule-change="false"> <el-form :model="model" :rules="rules" ref="modelForm" label-width="150px" label-position="right" size="small" :validate-on-rule-change="false">
<c-tabs v-model="tabVal" ref="elment" type="card" @tab-click="myTabClick"> <c-tabs v-model="tabVal" ref="elment" type="card" @tab-click="myTabClick">
<!--fxtfop PD000001 Registration --> <!--fxtfop PD000001 Registration -->
<el-tab-pane :label="$t('fxtfop.PD000001')" name="regp"> <el-tab-pane label="Registration" name="regp">
<m-regp :model="model" :codes="codes"/> <m-regp :model="model" :codes="codes"/>
</el-tab-pane> </el-tab-pane>
<el-tab-pane label="费用/账务" name="setpan">
<c-content>
<m-setpan :codes="codes" :model="model" />
</c-content>
</el-tab-pane>
<el-tab-pane label="报文/面函" name="docpan">
<c-content>
<m-docpan :codes="codes" :model="model" />
</c-content>
</el-tab-pane>
</c-tabs> </c-tabs>
</el-form> </el-form>
<c-function-btn
:handleCheck="handleCheck"
:handleStash="handleStash"
:handleSubmit="handleSubmit"
@handleSureWarning="handleSureWarning"
ref="commonBtn"></c-function-btn>
</c-page>
</div> </div>
</template> </template>
<script> <script>
...@@ -15,59 +33,52 @@ import Api from "~/service/Api" ...@@ -15,59 +33,52 @@ import Api from "~/service/Api"
import CodeTable from "~/config/CodeTable" import CodeTable from "~/config/CodeTable"
import Fxtfop from "../model" import Fxtfop from "../model"
import commonProcess from "~/mixin/commonProcess" import commonProcess from "~/mixin/commonProcess"
import Check from "../model/Check"
import Default from "../model/Default"
import Pattern from "../model/Pattern"
import Regp from "./Regp" import Regp from "./Regp"
import Setpan from "~/components/business/setmod/views";
import Docpan from "~/components/business/docpan/views";
import operationFunc from "~/mixin/operationFunc";
import commonDepend from "~/mixin/commonDepend";
import event from "../event";
import buildFn from "../event/buildCommons.js";
export default { export default {
name: "Fxtfop", name: "Fxtfop",
components:{ components:{
"m-regp" : Regp, "m-regp" : Regp,
"m-setpan": Setpan,
"m-docpan": Docpan,
}, },
provide() { provide() {
return { return {
root: this root: this
} }
}, },
mixins: [commonProcess], // 里面包含了Default、Check等的公共处理 mixins: [commonProcess,operationFunc,commonDepend,event,buildFn],
data(){ data(){
return { return {
tabVal: "", tabVal: "regp",
trnName: "fxtfop", trnName: "fxtfop",
trnType: "",
model: new Fxtfop().data, model: new Fxtfop().data,
checkRules: Check, codes: { ...CodeTable },
defaultRules: Default, rules: {},
pattern: Pattern,
rules: null,
codes: {
},
} }
}, },
methods:{ methods:{
myTabClick(tab){
this.tabClick(tab)
/**
* do it yourself
**/
}
}, },
created:async function(){ mounted() {
console.log("进入fxtfop交易"); console.log("进入fxtfop交易");
let rtnmsg = await this.init({}) let params = {
if(rtnmsg.respCode == SUCCESS) transName: this.trnName,
{ fxdgrp: {
this.updateModel(rtnmsg.data) rec: {
//TODO 处理数据逻辑 inr: this.$route.query.inr || "",
},
} },
else };
{ this.init(params)
this.$notify.error({title: '错误',message: '服务请求失败!'}); },
}
}
} }
</script> </script>
<style> <style>
......
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