index.vue 5.36 KB
Newer Older
1 2 3 4
<template>
    <c-page title="出口托收承兑">
        <div class="eContainer">
            <c-function-btn :handleSubmit="handleSubmit" :handleCheck="handleCheck" :handleStash="handleStash">
5 6 7 8 9 10 11
                <el-button size="small">备忘录</el-button>
                <el-button size="small">影像信息</el-button>
                <!-- <el-button size="small">保存模板</el-button> -->
                <!-- <el-button size="small">使用模板</el-button> -->
                <el-button size="small">制裁信息</el-button>
                <!-- <el-button size="small">拆分报文</el-button> -->
                <el-button size="small">智能提示</el-button>
12 13 14 15 16 17
            </c-function-btn>
            <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">

                    <!--PD000027 -->
18
                    <el-tab-pane label="Changing Maturity" name="setp">
nanrui committed
19
                        <m-setp ref="setp" :model="model" :codes="codes" />
20 21 22
                    </el-tab-pane>

                    <!--PD000049 -->
23
                    <el-tab-pane label="Instructions" name="inst">
24 25 26 27
                        <m-inst :model="model" :codes="codes" />
                    </el-tab-pane>

                    <!--PD000266 -->
28
                    <el-tab-pane label="Parties" name="ptyp">
29 30 31 32
                        <m-ptyp :model="model" :codes="codes" />
                    </el-tab-pane>

                    <!--PD000027 -->
nanrui committed
33
                    <el-tab-pane label="表外/或有" name="engp">
34 35 36 37
                        <m-engp :model="model" :codes="codes" />
                    </el-tab-pane>

                    <!--PD000000 -->
38
                    <!-- <el-tab-pane label="setpan" name="setpan">
39
                        <m-setpan :model="model" :codes="codes" />
40
                    </el-tab-pane> -->
nanrui committed
41
                    <el-tab-pane label="费用及账务" name="setpan">
42 43 44
                        <c-content>
                            <m-setpan :model="model" :codes="codes" />
                        </c-content>
45 46 47
                    </el-tab-pane>

                    <!--PD000000 -->
nanrui committed
48
                    <el-tab-pane label="附言" name="coninfp">
49 50 51 52
                        <m-coninfp :model="model" :codes="codes" />
                    </el-tab-pane>

                    <!--PD000529 -->
nanrui committed
53
                    <el-tab-pane label="面函" name="docpan">
54 55 56
                        <c-content>
                            <m-docpan :model="model" :codes="codes" />
                        </c-content>
57 58 59
                    </el-tab-pane>

                    <!--PD000546 -->
nanrui committed
60
                    <el-tab-pane label="附件" name="doctre">
61 62 63 64 65 66 67 68 69
                        <m-doctre :model="model" :codes="codes" />
                    </el-tab-pane>
                </c-tabs>
            </el-form>
        </div>
    </c-page>
</template>
<script>
import Api from "~/service/Api"
70
import Utils from "~/utils/index"
71 72
import CodeTable from "~/config/CodeTable"
import Botacc from "~/model/Botacc"
73
import commonFuncs from "~/mixin/commonFuncs"
74 75 76 77 78 79 80
import commonProcess from "~/mixin/commonProcess"
import Check from "~/model/Botacc/Check"
import Default from "~/model/Botacc/Default"
import Pattern from "~/model/Botacc/Pattern"
import Setp from "./Setp"
import Inst from "./Inst"
import Ptyp from "./Ptyp"
81
// import Engp from "./Engp"
82
// import Setpan from "./Setpan"
83
// import Coninfp from "./Coninfp"
84
// import Docpan from "./Docpan"
85
// import Doctre from "./Doctre"
86 87
import Setpan from "~/views/Public/Setpan"
import Docpan from "~/views/Public/Docpan"
88 89 90
import Engp from "~/views/Public/Engp"
import Doctre from "~/views/Public/Doctre"
import Coninfp from "~/views/Public/Coninfp"
91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112


export default {
    name: "Botacc",
    components: {
        "m-setp": Setp,
        "m-inst": Inst,
        "m-ptyp": Ptyp,
        "m-engp": Engp,
        "m-setpan": Setpan,
        "m-coninfp": Coninfp,
        "m-docpan": Docpan,
        "m-doctre": Doctre,
    },
    provide() {
        return {
            root: this
        }
    },
    mixins: [commonProcess, commonFuncs],    // 里面包含了Default、Check等的公共处理
    data() {
        return {
113
            tabVal: "setp",
114 115 116 117 118 119 120
            trnName: "botacc",
            model: new Botacc().data,
            checkRules: Check,
            defaultRules: Default,
            pattern: Pattern,
            rules: null,
            codes: {
121
                ...CodeTable
122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138
            },
        }
    },
    methods: {
        myTabClick(tab) {
            this.tabClick(tab)
            /**
            *  do it yourself
            **/
        }
    },
    created: async function () {
        console.log("进入botacc交易");
        let rtnmsg = await this.init({})
        if (rtnmsg.respCode == SUCCESS) {
            this.updateModel(rtnmsg.data)
            //TODO 处理数据逻辑
139 140 141
            if (this.isInDisplay) {
                this.restoreDisplay();
            }
nanrui committed
142 143 144 145
            this.$nextTick(() => {
                this.$refs.setp.$refs.table.$refs.table.toggleAllSelection();
                this.model.setmod.docamt = this.model.bodgrp.cbs.max.amt;
            })
146 147 148 149 150 151 152 153 154
        }
        else {
            this.$notify.error({ title: '错误', message: '服务请求失败!' });
        }
    }
}
</script>
<style>
</style>