<template>
  <div class="eContainer">
    <el-form :model="model" :rules="rules" ref="modelForm" label-width="200px" size="small" :validate-on-rule-change="false">
       <c-tabs v-model="tabVal" ref="elment" type="card" @tab-click="tabClick">
        
            <!--PD000010 -->
           <el-tab-pane label="Manager for Incoming Messages" name="tskmgr">
                <m-tskmgr :model="model" :codes="codes"/>
           </el-tab-pane>

           <el-tab-pane label="Incoming SWIFT" name="config1">
               <m-config :model="model" :codes="codes"/>
           </el-tab-pane>

           <el-tab-pane label="TradeConnect" name="config2">
               <m-config :model="model" :codes="codes"/>
           </el-tab-pane>

           <el-tab-pane label="Telex" name="config3">
               <m-config :model="model" :codes="codes"/>
           </el-tab-pane>

           <el-tab-pane label="DTA Export L/C" name="config4">
               <m-config :model="model" :codes="codes"/>
           </el-tab-pane>

           <el-tab-pane label="DTA Import L/C" name="config5">
               <m-config :model="model" :codes="codes"/>
           </el-tab-pane>

           <el-tab-pane label="E-mail" name="config6">
               <m-config :model="model" :codes="codes"/>
           </el-tab-pane>

           <el-tab-pane label="Bolero" name="config7">
               <m-config :model="model" :codes="codes"/>
           </el-tab-pane>

           <el-tab-pane label="ECL Import L/C" name="config8">
               <m-config :model="model" :codes="codes"/>
           </el-tab-pane>
           
 
            <!--PD000000 -->
           <!-- <el-tab-pane label="PD000000" name="filtskp">
                <m-filtskp :model="model" :codes="codes"/>
           </el-tab-pane> -->
 
            <!--PD000049 -->
           <!-- <el-tab-pane label="PD000049" name="prtswtr">
                <m-prtswtr :model="model" :codes="codes"/>
           </el-tab-pane> -->
 
            <!--PD000062 -->
           <!-- <el-tab-pane label="PD000062" name="prtswtrp">
                <m-prtswtrp :model="model" :codes="codes"/>
           </el-tab-pane> -->
 
            <!--PD000061 -->
           <!-- <el-tab-pane label="PD000061" name="xmldoc">
                <m-xmldoc :model="model" :codes="codes"/>
           </el-tab-pane> -->
 
            <!--PD000060 -->
           <!-- <el-tab-pane label="PD000060" name="prtswtp">
                <m-prtswtp :model="model" :codes="codes"/>
           </el-tab-pane> -->
 
            <!--PD000001 -->
           <!-- <el-tab-pane label="PD000001" name="config">
                <m-config :model="model" :codes="codes"/>
           </el-tab-pane> -->
 
 
            <!--PD000001 -->
           <!-- <el-tab-pane label="PD000001" name="prttst">
                <m-prttst :model="model" :codes="codes"/>
           </el-tab-pane> -->
 
 
 
            <!--PD000009 -->
           <!-- <el-tab-pane label="PD000009" name="dwndst">
                <m-dwndst :model="model" :codes="codes"/>
           </el-tab-pane> -->
       </c-tabs>
    </el-form>
  </div>
</template>
<script>
import Api from "~/service/Api"
import CodeTable from "~/config/CodeTable"
import Switsk from "~/model/Switsk"
import CommonProcess from "~/mixin/CommonProcess"
import Check from "~/model/Switsk/Check"
import Default from "~/model/Switsk/Default"
import Pattern from "~/model/Switsk/Pattern"
import Tskmgr from "./Tskmgr"
import Filtskp from "./Filtskp"
import Prtswtr from "./Prtswtr"
import Prtswtrp from "./Prtswtrp"
import Xmldoc from "./Xmldoc"
import Prtswtp from "./Prtswtp"
import Config from "./Config"
import Prttst from "./Prttst"
import Dwndst from "./Dwndst"


export default {
    components:{
        "m-tskmgr" : Tskmgr,
        "m-filtskp" : Filtskp,
        "m-prtswtr" : Prtswtr,
        "m-prtswtrp" : Prtswtrp,
        "m-xmldoc" : Xmldoc,
        "m-prtswtp" : Prtswtp,
        "m-config" : Config,
        "m-prttst" : Prttst,
        "m-dwndst" : Dwndst,
    },
    provide() {
        return {
            root: this
        }
    },
    mixins: [CommonProcess],    // 里面包含了Default、Check等的公共处理
    data(){
        return {
            tabVal: "tskmgr",
            trnName: "switsk",
            model: new Switsk().data,
            checkRules: Check,
            defaultRules: Default,
            pattern: Pattern,
            rules: null,
            codes: {...CodeTable},
        }
    },
    methods:{
        tabClick(){
        }
    },
    created:async function(){
        console.log("进入switsk交易");
        let rtnmsg = await this.init({})
        if(rtnmsg.respCode == SUCCESS)
        {
           //TODO 处理数据逻辑

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

</style>
