Commit 96cafc9a by 潘际乾

去掉页面加载时的校验、增加退出登录

parent 66b84e7a
...@@ -39,9 +39,6 @@ export default { ...@@ -39,9 +39,6 @@ export default {
params = params||{} params = params||{}
let data = Utils.flatObject(this.model) let data = Utils.flatObject(this.model)
const res = await Api.post(this.declareParams.trnName+"/checkAll",{...data,params}) const res = await Api.post(this.declareParams.trnName+"/checkAll",{...data,params})
if (res.respCode === SUCCESS) {
this.changeFormValidateDisabled(false);
}
return res return res
}, },
pedding(params){ pedding(params){
......
...@@ -9,12 +9,10 @@ export default { ...@@ -9,12 +9,10 @@ export default {
} }
}, },
created() { created() {
this.changeFormValidateDisabled(true);
}, },
mounted() { mounted() {
if(!this.isInDisplay){ if(!this.isInDisplay){
// this.ruleWatcher() // this.ruleWatcher()
this.changeFormValidateDisabled(true);
this.ruleCheck() this.ruleCheck()
} }
}, },
...@@ -81,13 +79,6 @@ export default { ...@@ -81,13 +79,6 @@ export default {
} }
} }
return "blur"; return "blur";
},
changeFormValidateDisabled(flag) {
const fields = this.$refs.modelForm.fields
for (let i = 0; i < fields.length; i++) {
const field = fields[i];
field.validateDisabled = flag
}
} }
}, },
computed:{ computed:{
......
...@@ -260,7 +260,7 @@ function defaultDidgrpRecExpplc() { ...@@ -260,7 +260,7 @@ function defaultDidgrpRecExpplc() {
} }
function defaultDidgrpAdvPtsBankno() { function defaultDidgrpAdvPtsBankno() {
const that = this; const that = this;
that.executeRule("executeRule").then(res => { that.executeRule("didgrp.adv.pts.bankno").then(res => {
//TODO //TODO
}) })
} }
......
...@@ -42,12 +42,12 @@ export default { ...@@ -42,12 +42,12 @@ export default {
{max: 3,message:"长度不能超过3"} {max: 3,message:"长度不能超过3"}
], ],
"didgrp.cbs.nom1.cur": [ "didgrp.cbs.nom1.cur": [
{required: true, message: "必输项"}, {required: true, message: "必输项", trigger: 'change'},
], ],
"didgrp.cbs.nom1.amt":[ "didgrp.cbs.nom1.amt":[
{required: true, message: "必输项"}, {required: true, message: "必输项", trigger: 'blur'},
{max: 18,message:"整数位不能超过14位"}, {max: 18,message:"整数位不能超过14位", trigger: 'blur'},
{pattern: /(^\d+$)|(^\.\d{1,3}$)|(^\d+\.\d{1,3}$)/, message: "小数位不能超过3位" } {pattern: /(^\d+$)|(^\.\d{1,3}$)|(^\d+\.\d{1,3}$)/, message: "小数位不能超过3位", trigger: 'blur'}
], ],
"didgrp.apl.namelc":[ "didgrp.apl.namelc":[
{type: "string", required: true, message: "必输项"}, {type: "string", required: true, message: "必输项"},
...@@ -201,8 +201,8 @@ export default { ...@@ -201,8 +201,8 @@ export default {
], ],
"didgrp.blk.lcrgod":[ "didgrp.blk.lcrgod":[
{type: "string", required: false, message: "必输项"}, {type: "string", required: false, message: "必输项", trigger: "blur"},
{max: 1430,message:"长度不能超过1430"} {max: 1430,message:"长度不能超过1430", trigger: "blur"}
], ],
"didgrp.blk.lcrdoc":[ "didgrp.blk.lcrdoc":[
......
...@@ -54,7 +54,7 @@ ...@@ -54,7 +54,7 @@
<el-col :span="6"> <el-col :span="6">
<el-form-item label="信用证金额" prop="didgrp.cbs.nom1.cur"> <el-form-item label="信用证金额" prop="didgrp.cbs.nom1.cur">
<c-select v-model="model.didgrp.cbs.nom1.cur" style="width:100%" placeholder="请选择Currency" @blur="selectBlur"> <c-select v-model="model.didgrp.cbs.nom1.cur" style="width:100%" placeholder="请选择Currency">
<el-option v-for="item in codes.cur" :key="item.value" :label="item.label" <el-option v-for="item in codes.cur" :key="item.value" :label="item.label"
:value="item.value"> :value="item.value">
</el-option> </el-option>
...@@ -63,7 +63,7 @@ ...@@ -63,7 +63,7 @@
</el-col> </el-col>
<el-col :span="6" > <el-col :span="6" >
<el-form-item style="text-align:left" label-width="20px" prop="didgrp.cbs.nom1.amt"> <el-form-item style="text-align:left" label-width="20px" prop="didgrp.cbs.nom1.amt">
<c-input v-model.lazy="model.didgrp.cbs.nom1.amt" style="text-align:left;width:100%" placeholder="请输入信用证金额"></c-input> <c-input v-model="model.didgrp.cbs.nom1.amt" style="text-align:left;width:100%" placeholder="请输入信用证金额"></c-input>
</el-form-item> </el-form-item>
</el-col> </el-col>
...@@ -417,9 +417,6 @@ export default { ...@@ -417,9 +417,6 @@ export default {
this.model.didgrp.ben.adrelc = data.didgrp_ben_adrelc; this.model.didgrp.ben.adrelc = data.didgrp_ben_adrelc;
this.model.didgrp.ben.pts.extkey = data.didgrp_ben_pts_extkey; this.model.didgrp.ben.pts.extkey = data.didgrp_ben_pts_extkey;
}) })
},
selectBlur(e) {
console.log(e)
} }
}, },
created:function(){ created:function(){
......
<template> <template>
<c-page title="买方信用证开立"> <c-page title="买方信用证开立">
<div class="eContainer"> <div class="eContainer">
<el-form :model="model" :rules="rules" ref="modelForm" label-width="200px" size="small"> <el-form :model="model" :rules="rules" ref="modelForm" label-width="200px" size="small" :validate-on-rule-change="false">
<el-tabs ref="elment" type="card" @tab-click="tabClick"> <el-tabs ref="elment" type="card" @tab-click="tabClick">
<el-tab-pane label="内容"> <el-tab-pane label="内容">
<!--PD000001 --> <!--PD000001 -->
......
<template> <template>
<div class="self-header"> <div class="self-header">
<h2 class="self_header_label">新一代银行国际结算系统</h2> <h2 class="self_header_label">新一代银行国际结算系统</h2>
<div class="user-operate">
<span @click="logout">退出登录</span>
</div>
</div> </div>
</template> </template>
<script> <script>
export default { export default {
methods: {
logout() {
this.$store.commit("UserContext/setLogout");
this.$router.push("/login");
}
}
} }
</script> </script>
...@@ -29,4 +37,15 @@ export default { ...@@ -29,4 +37,15 @@ export default {
top:15px; top:15px;
left:2em; left:2em;
} }
.user-operate{
position: absolute;
right: 20px;
color: #FFF;
}
.user-operate span{
cursor: pointer;
}
.user-operate span:hover{
color: #e6a23c;
}
</style> </style>
\ 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