<template>
  <div class="eibs-tab">
    <!-- ====================左边======================= -->
    <c-col :span="12">
      <c-col :span="20">
        <el-form-item
          label="国内信用证项下开证授信额度:"
          prop="liaall.limmod.limpts.wrk.pts.extkey"
          style="width: 100%"
        >
          <c-input
            v-model="model.liaall.limmod.limpts.wrk.pts.extkey"
            :disabled="true"
            maxlength="16"
            placeholder="请输入External Key of Address"
            style="width: 95%"
          ></c-input>
        </el-form-item>
      </c-col>

      <c-col :span="1">
        <div class="button_contains">
          <c-button
            style="margin: 0 10px 0 0; padding: 0 10px"
            size="small"
            type="primary"
            icon="el-icon-search"
            @click="onSeainf"
          ></c-button>
        </div>
      </c-col>
      <c-col :span="3">
        <div class="button_contains">
          <c-button
            style="margin: 0 0"
            size="small"
            type="primary"
            icon="el-icon-search"
            @click="onPreperButtxmsel"
          >
            详情
          </c-button>
        </div>
      </c-col>

      <c-col :span="24">
        <el-form-item label="" prop="liaall.limmod.limpts.wrk.pts.nam">
          <c-input
            v-model="model.liaall.limmod.limpts.wrk.pts.nam"
            maxlength="16"
            placeholder=""
            :disabled="true"
            style="width: 90%"
          ></c-input>
        </el-form-item>
      </c-col>

      <c-col :span="18">
        <el-form-item label="额度类型" prop="liaall.limmod.limpts.nonrevflg1">
          <c-select
            v-model="model.liaall.limmod.limpts.nonrevflg1"
            style="width: 100%"
            placeholder="请选择Flag to Mark Non-revolving Limits"
            @change="nonrevflg1Change"
          >
            <el-option
              v-for="item in codes.nonrevflg1"
              :key="item.value"
              :label="item.label"
              :value="item.value"
            >
            </el-option>
          </c-select>
        </el-form-item>
      </c-col>

      <c-col :span="6">
        <div class="button_contains">
          <c-button size="small" type="primary" @click="onLimptsGet1">
            查询
          </c-button>
        </div>
      </c-col>

      <c-col :span="24">
        <el-form-item label="合同流水号" prop="liaall.limmod.limpts.pfcod1">
          <c-input
            v-model="model.liaall.limmod.limpts.pfcod1"
            maxlength="14"
            placeholder="请输入合同流水号"
            :disabled="this.model.liaall.limmod.limpts.nonrevflg1 != '2'"
            style="width: 55%"
          ></c-input>
        </el-form-item>
      </c-col>
    </c-col>

    <!-- ========================右边======================= -->
    <c-col :span="12">
      <c-col :span="24">
        <el-form-item label="业务编号" prop="liaall.limmod.ownref">
          <c-input
            v-model="model.liaall.limmod.ownref"
            maxlength="16"
            placeholder="请输入国结业务编号"
            :disabled="true"
            style="width: 70%"
          ></c-input>
        </el-form-item>
      </c-col>

      <c-col :span="24">
        <el-form-item label="业务余额" prop="liaall.limmod.comamt">
          <c-input
            v-model="model.liaall.limmod.comamt"
            placeholder="请输入业务余额"
            :disabled="true"
            style="width: 70%"
          ></c-input>
        </el-form-item>
      </c-col>

      <c-col :span="24">
        <el-form-item label="保证金余额" prop="liaall.limmod.ccvamt">
          <c-input
            v-model="model.liaall.limmod.ccvamt"
            placeholder="请输入保证金余额"
            :disabled="true"
            style="width: 70%"
          ></c-input>
        </el-form-item>
      </c-col>
    </c-col>

    <c-col :span="22" :offset="1">
      <c-table style="text-align: center" :data="tableData" :border="true">
        <el-table-column label="可否串用" width="auto"> </el-table-column>
        -->
        <el-table-column label="序号" width="auto"> </el-table-column>
        <el-table-column label="额度类型" width="auto"> </el-table-column>
        <el-table-column label="入账机构" width="auto"> </el-table-column>
        <el-table-column label="额度编号" width="auto"> </el-table-column>
        <el-table-column label="额度明细编号" width="auto"> </el-table-column>
        <el-table-column label="额度品种代码" width="auto"> </el-table-column>
        <el-table-column label="品种代码描述" width="auto"> </el-table-column>
        <el-table-column label="" width="auto"> </el-table-column>
      </c-table>
    </c-col>
  </div>
</template>
<script>
import Api from "~/service/Api";
import CommonProcess from "~/mixin/CommonProcess";
import CodeTable from "~/config/CodeTable";
import Event from "~/model/Bdtudp/Event";

export default {
  inject: ["root"],
  props: ["model", "codes"],
  mixins: [CommonProcess],
  data() {
    return {
      tableData: {},
    };
  },
  methods: {
    ...Event,
    nonrevflg1Change() {
      if (this.model.liaall.limmod.limpts.nonrevflg1 == "1") {
        this.model.liaall.limmod.limpts.pfcod1 = "";
      }
    },
  },
  created: function () {},
};
</script>
<style>
.button_contains {
  display: flex;
  text-align: center;
}
</style>
