<!--
  @description: 商务技术标解密失败投标人信息\经济标解密失败投标人信息
  @Modifier: hefei
  @routerPath: /bidding/bidOpening/bidOpeningMonitor/bidOpeningMonitorDetail/decFailSupplierData-detail
  @date: 2021/03/08 11:35:59
-->
<template>
  <div>
    <dl class="projectInfoDetail">
      <dd>
        <el-table
          v-loading="loading"
          :data="tableData"
        >
          <el-table-column
            type="index"
            label="序号"
            min-width="60px"
            align="center"
          />
          <el-table-column
            prop="packName"
            label="标段（包）名称"
            header-align="center"
            min-width="140px"
          />
          <el-table-column
            prop="supplierName"
            label="供应商名称"
            min-width="140px"
            header-align="center"
          />
          <!-- 解密数据 decryptionMethod为00 客户端解密 -->
          <template v-if="this.$route.params.decryptionMethod === '00'">
            <el-table-column
              prop="telephone"
              :label="label"
              min-width="140px"
              header-align="center"
            />
          </template>
        </el-table>
      </dd>
    </dl>
  </div>
</template>
<script>
/* api */
import { getTechnicalOpeningDecFailSupplier } from '@/api/bidding/bidOpening' // 商务技术标解密失败投标人信息
import { getEconomicDecFailSupplier } from '@/api/bidding/bidOpening' // 经济标解密失败投标人信息
import { getOpenBidDecryptFailSupplier } from '@/api/bidding/bidOpening' // 经济标解密失败投标人信息
export default {
  name: 'GetDecFailSupplier',
  props: {
    bidSignDecrypt: {
      type: Object,
      default: function() {
        return {}
      }
    }
  },
  data() {
    return {
      label: '',
      loading: false, // 列表loading
      tableData: [] // 列表
    }
  },
  methods: {
    // 查询数据
    getTechnicalOpeningDecFailSupplier() {
      this.label = '商务技术标签到手机号'
      this.tableData = []
      this.loading = true
      getTechnicalOpeningDecFailSupplier(this.bidSignDecrypt).then(response => {
        this.loading = false
        this.tableData = response.data
      }).catch(() => {
        this.loading = false
      })
    },
    getEconomicDecFailSupplier() {
      this.label = '经济标签到手机号'
      this.tableData = []
      this.loading = true
      getEconomicDecFailSupplier(this.bidSignDecrypt).then(response => {
        this.loading = false
        this.tableData = response.data
      }).catch(() => {
        this.loading = false
      })
    },
    // 一步开标客户端解密失败投标人信息
    getOpenBidDecryptFailSupplier() {
      this.label = '签到手机号'
      this.tableData = []
      this.loading = true
      getOpenBidDecryptFailSupplier(this.bidSignDecrypt).then(response => {
        this.loading = false
        this.tableData = response.data
      }).catch(() => {
        this.loading = false
      })
    }
  }
}
</script>
<style lang="less" scoped>

</style>
