index.vue 4.1 KB
Newer Older
chenzhaole committed
1
<template>
LiRui committed
2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19
  <div class="eContainer">
    <c-page title="境内外币汇入汇款">
      <el-form
        :model="model"
        :rules="rules"
        ref="modelForm"
        label-width="120px"
        label-position="right"
        size="small"
        :validate-on-rule-change="false"
      >
        <c-tabs
          v-model="tabVal"
          ref="elment"
          type="card"
          @tab-click="myTabClick"
        >
          <el-tab-pane label="业务信息" name="ovwp">
20
            <c-content>
LiRui committed
21
              <m-ovwp :model="model" :codes="codes" />
22 23
            </c-content>
          </el-tab-pane>
LiRui committed
24
          <el-tab-pane label="费用/账务" name="setpan">
25
            <c-content>
LiRui committed
26 27 28 29 30 31 32 33
              <div class="eibs-tab">
                <el-collapse v-model="activeNames">
                  <el-collapse-item title="结算" name="setpan">
                    <!-- 结算 -->
                    <m-setpan :model="model" :codes="codes" />
                  </el-collapse-item>
                </el-collapse>
              </div>
34 35
            </c-content>
          </el-tab-pane>
LiRui committed
36
          <el-tab-pane label="备查/附言" name="addbcb">
37
            <c-content>
LiRui committed
38
              <m-addbcb :model="model" :codes="codes" />
39 40 41
            </c-content>
          </el-tab-pane>

LiRui committed
42
          <el-tab-pane label="申报信息" name="cnyp">
43
            <c-content>
LiRui committed
44
              <m-cnyp :model="model" :codes="codes" />
45 46 47
            </c-content>
          </el-tab-pane>

nanrui committed
48
          <!-- 报文和面函 -->
LiRui committed
49
          <el-tab-pane label="报文/面函" name="docpan">
50
            <c-content>
taojinrui committed
51
              <m-docpan :model="model" :codes="codes" />
52 53 54
            </c-content>
          </el-tab-pane>

nanrui committed
55
          <!--附件 -->
LiRui committed
56
          <el-tab-pane label="附件信息" name="doctre">
57 58 59 60 61 62
            <c-content>
              <m-doctre :model="model" :codes="codes" />
            </c-content>
          </el-tab-pane>
        </c-tabs>
      </el-form>
taojinrui committed
63

LiRui committed
64 65 66 67 68
      <c-grid-ety-prompt-dialog
        ref="etyDialog"
        :promptData="promptData"
        v-on:select-ety="selectEty"
      >
69
      </c-grid-ety-prompt-dialog>
taojinrui committed
70

LiRui committed
71 72 73 74 75 76 77 78 79
      <!-- <c-bus-button :$pntvm="this"></c-bus-button> -->
      <c-function-btn
        :handleSubmit="handleSubmit"
        :handleCheck="handleCheck"
        :handleStash="handleStash"
      >
      </c-function-btn>
    </c-page>
  </div>
chenzhaole committed
80 81
</template>
<script>
82
import Api from "~/service/Api";
taojinrui committed
83
import Utils from "~/utils/index";
84 85 86 87 88 89
import CodeTable from "~/config/CodeTable";
import Cptati from "~/model/Cptati";
import commonProcess from "~/mixin/commonProcess";
import Check from "~/model/Cptati/Check";
import Default from "~/model/Cptati/Default";
import Pattern from "~/model/Cptati/Pattern";
90 91
import commonFuncs from "~/mixin/commonFuncs";

LiRui committed
92
import Ovwp from "./Ovwp";
93
import Pardet from "./Pardet";
LiRui committed
94 95
import Cnyp from "./Cnyp";
import Addbcb from "./Addbcb.vue";
96 97 98 99

import Doctre from "~/views/Public/Doctre";
import Docpan from "~/views/Public/Docpan";
import Setpan from "~/views/Public/Setpan";
taojinrui committed
100

chenzhaole committed
101
export default {
102 103
  name: "Cptati",
  components: {
LiRui committed
104
    "m-ovwp": Ovwp,
105 106
    "m-pardet": Pardet,
    "m-setpan": Setpan,
LiRui committed
107
    "m-addbcb": Addbcb,
108 109
    "m-doctre": Doctre,
    "m-docpan": Docpan,
LiRui committed
110
    "m-cnyp": Cnyp,
111 112 113 114 115 116
  },
  provide() {
    return {
      root: this,
    };
  },
117
  mixins: [commonProcess, commonFuncs], // 里面包含了Default、Check等的公共处理
118 119
  data() {
    return {
LiRui committed
120
      tabVal: "ovwp",
121 122 123 124 125 126
      trnName: "cptati",
      model: new Cptati().data,
      checkRules: Check,
      defaultRules: Default,
      pattern: Pattern,
      rules: null,
LiRui committed
127
      activeNames: ["setpan"],
128 129 130 131 132 133 134 135 136
      codes: { ...CodeTable },
    };
  },
  methods: {
    myTabClick(tab) {
      this.tabClick(tab);
      /**
       *  do it yourself
       **/
137
    },
138 139 140 141 142 143 144
  },
  created: async function () {
    console.log("进入cptati交易");
    let rtnmsg = await this.init({});
    if (rtnmsg.respCode == SUCCESS) {
      this.updateModel(rtnmsg.data);
      //TODO 处理数据逻辑
145
      if (this.isInDisplay) {
146
        this.restoreDisplay();
taojinrui committed
147
      }
148 149
    } else {
      this.$notify.error({ title: "错误", message: "服务请求失败!" });
chenzhaole committed
150
    }
151 152
  },
};
chenzhaole committed
153 154 155
</script>
<style>
</style>