index.vue 2.62 KB
Newer Older
1
<template>
huangxin committed
2
    <c-page title="改 -- 国内外汇贷款">
3
  <div class="eContainer">
huangxin committed
4
    <el-form :model="model" :rules="rules" ref="modelForm" label-width="120px" label-position="right" size="small" :validate-on-rule-change="false">
5 6
       <c-tabs v-model="tabVal" ref="elment" type="card" @tab-click="myTabClick">
                   <!--cfabut PD000002 接口数据 -->
huangxin committed
7 8
           <el-tab-pane label="接口数据" name="sel">
            <c-content>
9
                <m-sel :model="model" :codes="codes"/>
huangxin committed
10
                </c-content>
11 12
           </el-tab-pane>
            <!--ecap PD000001 国内外汇贷款-签约信息 -->
huangxin committed
13 14
           <el-tab-pane label="国内外汇贷款-签约信息" name="conp">
            <c-content>
15
                <m-conp :model="model" :codes="codes"/>
huangxin committed
16
                </c-content>
17 18 19
           </el-tab-pane>
       </c-tabs>
    </el-form>
huangxin committed
20
    <c-function-btn
21 22
        :handleSubmit="handleSubmit.bind(this,'cfabut.sav')"
        :handleCheck="handleCheck.bind(this,'cfabut.chk')"
huangxin committed
23 24 25
        :handleStash="handleStash"
      >
      </c-function-btn>
26
  </div>
huangxin committed
27
  </c-page>
28 29 30 31 32 33
</template>
<script>
import Api from "~/service/Api"
import CodeTable from "~/config/CodeTable"
import Ecaame from "~/model/Ecaame"
import commonProcess from "~/mixin/commonProcess"
huangxin committed
34
import commonFuncs from "~/mixin/commonFuncs";
35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52
import Check from "~/model/Ecaame/Check"
import Default from "~/model/Ecaame/Default"
import Pattern from "~/model/Ecaame/Pattern"
import Sel from "./Sel"
import Conp from "./Conp"


export default {
    name: "Ecaame",
    components:{
        "m-sel" : Sel,
        "m-conp" : Conp,
    },
    provide() {
        return {
            root: this
        }
    },
huangxin committed
53
    mixins: [commonProcess,commonFuncs],    // 里面包含了Default、Check等的公共处理
54 55
    data(){
        return {
huangxin committed
56
            tabVal: "sel",
57 58 59 60 61 62 63
            trnName: "ecaame",
            trnType: "",
            model: new Ecaame().data,
            checkRules: Check,
            defaultRules: Default,
            pattern: Pattern,
            rules: null,
64
            codes: {...CodeTable
65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94
            },
        }
    },
    methods:{
        myTabClick(tab){
            this.tabClick(tab)
            /**
            *  do it yourself
            **/
        }
    },
    created:async function(){
        console.log("进入ecaame交易");
        let rtnmsg = await this.init({})
        if(rtnmsg.respCode == SUCCESS)
        {
           this.updateModel(rtnmsg.data)
           //TODO 处理数据逻辑

        }
        else
        {
            this.$notify.error({title: '错误',message: '服务请求失败!'});
        }
    }
}
</script>
<style>

</style>