Infsea.vue 11.3 KB
Newer Older
潘际乾 committed
1
<template>
2
  <div class="eibs-tab">
潘际乾 committed
3 4 5
    <c-list-search @form-reset="handleReset" @form-search="handleSearch">
      <!-- 持续展示区 -->
      <template v-slot="searchSlot">
6
        <el-form class="m-table-search-form" ref="paramsForm" label-position="right" label-width="110px" size="small">
潘际乾 committed
7
          <c-row>
8 9 10 11 12
            <c-col :span="8">
              <el-form-item label="保函编号" prop="infcon.seaownref" style="width: 100%">
                <c-input v-model="model.infcon.seaownref" maxlength="16" placeholder="请输入保函编号"></c-input>
              </el-form-item>
            </c-col>
潘际乾 committed
13

14 15 16 17 18 19 20 21 22 23 24 25 26 27 28
            <c-col :span="8">
              <el-form-item label="开立日期" prop="infcon.opndatfrom" style="width: 100%">
                <c-col :span="11">
                  <c-date-picker type="date" v-model="model.infcon.opndatfrom" style="width: 100%" placeholder="请选择起始日期"
                    value-format="yyyy-MM-dd"></c-date-picker>
                </c-col>
                <c-col :span="2" style="text-align: center">
                  <label style="display: inline-block; width: 100%">-</label>
                </c-col>
                <c-col :span="11">
                  <c-date-picker type="date" v-model="model.infcon.opndatto" style="width: 100%" placeholder="请选择截止日期"
                    value-format="yyyy-MM-dd"></c-date-picker>
                </c-col>
              </el-form-item>
            </c-col>
潘际乾 committed
29

30 31 32 33 34
            <c-col :span="8">
              <el-form-item label="进口/出口保函" style="width: 100%">
                <c-select v-model="isGuarantee" style="width: 100%" placeholder="请选择进口/出口保函" :code="codes.guarantee">
                </c-select>
              </el-form-item>
潘际乾 committed
35 36 37 38 39
            </c-col>
          </c-row>

          <!-- 可控展示区 -->
          <c-row v-show="searchSlot.searchToggle">
40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72
            <c-col :span="8">
              <el-form-item label="业务简略信息" prop="infcon.nam" style="width: 100%">
                <c-input v-model="model.infcon.nam" maxlength="40" placeholder="请输入业务简略信息"></c-input>
              </el-form-item>
            </c-col>
            <c-col :span="8">
              <el-form-item label="当事人编号" prop="infcon.pty.extkey" style="width: 100%">
                <c-input v-model="model.infcon.pty.extkey" maxlength="16" placeholder="请输入当事人编号"></c-input>
              </el-form-item>
            </c-col>
            <c-col :span="8">
              <el-form-item label="当事人BIC编码" prop="infcon.seapty" style="width: 100%">
                <c-input v-model="model.infcon.seapty" maxlength="24" placeholder="请输入当事人BIC编码"></c-input>
              </el-form-item>
            </c-col>

            <c-col :span="8">
              <el-form-item label="当事人名称" prop="infcon.pty.nam" style="width: 100%">
                <c-input v-model="model.infcon.pty.nam" maxlength="40" placeholder="请输入当事人名称"></c-input>
              </el-form-item>
            </c-col>
            <c-col :span="8">
              <el-form-item label="当事人角色" prop="infcon.searol" style="width: 100%">
                <c-select v-model="model.infcon.searol" style="width: 100%" placeholder="请选择当事人角色">
                  <el-option v-for="item in codes.payrol" :key="item.value" :label="item.label" :value="item.value">
                  </el-option>
                </c-select>
              </el-form-item>
            </c-col>
            <c-col :span="8">
              <el-form-item label="客户经理" prop="infcon.usr.extkey" style="width: 100%">
                <c-input v-model="model.infcon.usr.extkey" maxlength="24" placeholder="请输入客户经理"></c-input>
              </el-form-item>
潘际乾 committed
73 74
            </c-col>

75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102
            <c-col :span="8">
              <el-form-item label="业务状态" prop="infcon.seasta" style="width: 100%">
                <c-select v-model="model.infcon.seasta" style="width: 100%" placeholder="请选择业务状态">
                  <el-option v-for="item in codes.seasta" :key="item.value" :label="item.label" :value="item.value">
                  </el-option>
                </c-select>
              </el-form-item>
            </c-col>
            <c-col :span="8">
              <el-form-item label="币种" prop="infcon.seacur" style="width: 100%">
                <c-select v-model="model.infcon.seacur" style="width: 100%" placeholder="请选择币种">
                  <el-option v-for="item in codes.curtxt1" :key="item.value" :label="item.label" :value="item.value">
                  </el-option>
                </c-select>
              </el-form-item>
            </c-col>
            <c-col :span="8">
              <el-form-item label="金额区间" prop="infcon.seaamtfr" style="width: 100%">
                <c-col :span="11">
                  <c-input v-model="model.infcon.seaamtfr" style="width: 100%" placeholder="请输入金额下限"></c-input>
                </c-col>
                <c-col :span="2" style="text-align: center">
                  <label style="display: inline-block; width: 100%">-</label>
                </c-col>
                <c-col :span="11">
                  <c-input v-model="model.infcon.seaamtto" style="width: 100%" placeholder="请输入金额上限"></c-input>
                </c-col>
              </el-form-item>
潘际乾 committed
103 104
            </c-col>

105 106 107 108
            <c-col :span="8">
              <el-form-item label="当事人参考号" prop="infcon.searef" style="width: 100%">
                <c-input v-model="model.infcon.searef" maxlength="16" placeholder="请输入当事人参考号"></c-input>
              </el-form-item>
潘际乾 committed
109
            </c-col>
110

111 112 113 114 115
            <c-col :span="8">
              <el-form-item label="承诺类型" prop="seagtyp" style="width: 100%">
                <c-select v-model="model.seagtyp" style="width: 100%" placeholder="请选择承诺类型" :code="codes.seagtyp">
                </c-select>
              </el-form-item>
潘际乾 committed
116 117 118 119 120
            </c-col>
          </c-row>
        </el-form>
      </template>
    </c-list-search>
121
    <div style="height:90%">
wangna committed
122
      <c-col :span="24">
nanrui committed
123
        <c-istream-table :list="stmData.data" :columns="stmData.columns" :showButtonFlg="true">
wangna committed
124 125
          <el-table-column fixed="right" prop="op" label="操作" width="140px">
            <template slot="header">
126
              <c-col :span="11" style="text-align: center"><span>操作</span></c-col>
nanrui committed
127
              <!-- <c-col :span="12" style="text-align: right">
128 129
                    <c-button icon="el-icon-s-tools"></c-button>
                  </c-col> -->
wangna committed
130 131
            </template>
            <template slot-scope="scope">
132
              <el-popover placement="top-start" title="历史信息" width="800" trigger="click" :ref="'popover_' + scope.row.IDX">
nanrui committed
133
                <div style="
134 135 136 137 138
                        text-align: right;
                        margin-top: -30px;
                        margin-right: 5px;
                        font-size: 16px;
                      ">
nanrui committed
139
                  <span class="el-icon-close" @click="closeTrn('popover_' + scope.row.IDX)" />
wangna committed
140
                </div>
nanrui committed
141
                <c-istream-table :list="trnData.data" :columns="trnData.columns">
wangna committed
142 143
                  <el-table-column prop="op" label="操作" width="0">
                    <template slot-scope="scope">
nanrui committed
144
                      <c-button style="margin-left: 0" size="small" @click="display(scope.row['INR'])">详情</c-button>
wangna committed
145 146 147
                    </template>
                  </el-table-column>
                </c-istream-table>
148 149
                <c-button style="margin-left: 0" size="small" @click="getTrnInfo(scope.$index, scope.row)" slot="reference">
                  详情</c-button>
wangna committed
150
              </el-popover>
nanrui committed
151 152
              <c-button style="margin-left: 5px" size="small" type="primary" @click="getButtons(scope.row['保函编号'])">
                处理</c-button>
wangna committed
153 154 155 156
            </template>
          </el-table-column>
        </c-istream-table>
      </c-col>
157
    </div>
潘际乾 committed
158

wangna committed
159
    <div v-if="dialogFlag" class="m-list-btns">
nanrui committed
160 161
      <m-busbtn ref="childs" :ownref="ownref" trnCode="gitsel" ownrefPath="gcdgrp" :model="gitselModel" tabIndex="3"
        @onChoose="onChoose">11</m-busbtn>
wangna committed
162 163
    </div>
    <div v-else>
nanrui committed
164 165
      <m-busbtn ref="childs" :ownref="ownref" trnCode="getsel" ownrefPath="gcdgrp" :model="getselModel" tabIndex="3"
        @onChoose="onChoose">11</m-busbtn>
wangna committed
166
    </div>
潘际乾 committed
167 168 169 170 171 172 173 174
  </div>
</template>
<script>
import Api from "~/service/Api";
import commonProcess from "~/mixin/commonProcess";
import CodeTable from "~/config/CodeTable";
import Event from "~/model/Infgcd/Event";

wangna committed
175 176 177 178
import GitselModel from "~/model/Gitsel";
import GetselModel from "~/model/Getsel";
import BusNavbar from "~/views/Public/BusNavbar";

潘际乾 committed
179 180 181 182
export default {
  inject: ["root"],
  props: ["model", "codes"],
  mixins: [commonProcess],
wangna committed
183
  components: { "m-busbtn": BusNavbar },
潘际乾 committed
184 185
  data() {
    return {
wangna committed
186 187 188
      gitselModel: new GitselModel().data,
      getselModel: new GetselModel().data,
      ownref: "",
潘际乾 committed
189
      dialogTableVisible: false,
wangna committed
190
      dialogFlag: true,
nanrui committed
191
      isGuarantee: '',
潘际乾 committed
192 193
      trnData: {
        columns: [
wangna committed
194 195
          '0 1 "交易ID" 100',
          '1 2 "交易名称" 200',
wangna committed
196
          '2 3 "条目" 200',
197 198 199 200 201
          {
            index: 3,
            position: 4,
            width: 100,
            pattern: "code",
wangna committed
202
            label: "状态",
203 204
            code: this.codes.relflg,
          },
wangna committed
205 206 207
          '4 5 "币种" 80',
          '5 6 "相关金额" 150',
          '6 7 "标识" 100',
潘际乾 committed
208 209 210 211 212
        ],
        data: [],
      },
      stmData: {
        columns: [
wangna committed
213 214 215 216 217 218 219 220 221 222 223 224
          '1 1 "保函编号" 150',
          '2 2 "客户经理" 150',
          '5 3 "第一当事人编号" 150',
          '6 4 "申请人名称" 150',
          '7 5 "第二当事人编号" 150',
          '8 6 "受益人名称" 150',
          '3 7 "开立日期" 150',
          '4 8 "关闭日期" 150',
          '9 9 "原始金额币种" 150',
          '10 10 "原始金额" 150',
          '11 11 "余额币种" 150',
          '12 12 "余额" 150',
潘际乾 committed
225 226 227 228 229
        ],
        data: [],
      },
    };
  },
wangna committed
230
  methods: {
潘际乾 committed
231
    ...Event,
wangna committed
232 233 234 235 236 237 238
    async getButtons(ownref) {
      this.ownref = ownref;
      this.$refs.childs.initdialog = true;
      this.dialogFlag = ownref.startsWith("LG");
      console.log("dialogFlag:" + this.dialogFlag);
      console.log("ownref:" + ownref);
    },
潘际乾 committed
239 240 241
    async onChoose(code) {
      //跳转交易
      this.$router.history.push("/business/" + code);
wangna committed
242 243 244 245 246 247
      this.$refs.childs.initdialog = false;
    },
    async getDitSelInfo(code) {
      //跳转交易
      this.$router.history.push("/business/" + code);
      this.$refs.childs.initdialog = false;
潘际乾 committed
248 249 250 251 252 253 254 255 256 257 258 259 260 261 262 263 264
    },

    async getTrnInfo(idx, row) {
      this.model.infcon.objinr = row["INR"];
      this.model.gidgrp.rec.inr = row["INR"];
      this.model.infcon.chksubcon = "X";

      this.dialogTableVisible = true;
      let rtnmsg = await this.executeDefault("infcon.chksubcon");

      if ((rtnmsg.respCode = SUCCESS)) {
        this.trnData.data = rtnmsg.data.infcon_trnstm.rows;
      }
    },
    closeTrn(refId) {
      this.$refs[refId].doClose();
    },
wangna committed
265 266 267 268 269 270
    // handleReset: function () {
    //   this.model = {
    //     instNo: "",
    //     instName: "",
    //   };
    // },
潘际乾 committed
271
  },
nanrui committed
272
  created: function () { },
wangna committed
273
  watch: {
nanrui committed
274
    "model.gidgrp.rec.ownref": function () { },
wangna committed
275
  },
潘际乾 committed
276 277 278
};
</script>
<style>
279
.m-table-search {
280
  padding: 20px 0px 10px 0px;
281
}
潘际乾 committed
282
</style>