<!--
  @description: 标书费退款开票信息
  @Modifier: sunxinman/haofengxian
  @routerPath: /fee/tenderFeeRefundInvoiceDetail
  @date: 2020/04/01-14:30
-->
<template>
  <div>
    <section class="title p0-16 clearfix">
      <!-- 返回 -->
      <div class="title-back pointer" @click="back()">
        <i class="iconfont icon-fanhui mr10" />查看开票信息
      </div>
    </section>
    <section class="p0-16">
      <!-- 表格部分 -->
      <table class="tableData">
        <tr>
          <td>招标项目编号</td>
          <td>{{ formData.tenderNo }}</td>
          <td>招标项目名称</td>
          <td>{{ formData.tenderName }}</td>
        </tr>
        <tr>
          <td>标段（包）编号</td>
          <td>{{ formData.packNo }}</td>
          <td>标段（包）名称</td>
          <td>{{ formData.packName }}</td>
        </tr>
        <tr>
          <td>行业分类</td>
          <td>{{ formData.projectIndustryName }}</td>
          <td>业务部门</td>
          <td>{{ formData.department }}</td>
        </tr>
        <tr>
          <td>项目经理</td>
          <td>{{ formData.tenderManager }}</td>
          <td>投标人</td>
          <td>{{ formData.supplierName }}</td>
        </tr>
        <tr>
          <td>纳税人识别号</td>
          <td>{{ formData.taxpayerIdentificationNumber }}</td>
          <td>地址、电话</td>
          <td>{{ formData.address }}{{ formData.phone }}</td>
        </tr>
        <tr>
          <td>开户银行及账号</td>
          <td>{{ formData.bank }}{{ formData.number }}</td>
          <td>联行号</td>
          <td>{{ formData.uniteCode }}</td>
        </tr>
        <tr>
          <td>支付方式</td>
          <td>
            {{ filterDictText(paymentMethodList,formData.payMode) }}
          </td>
          <td>开票金额（元）</td>
          <td>{{ formData.documentPrice }}</td>
        </tr>
        <tr>
          <td>不含税金额（元）</td>
          <td>{{ formData.noTaxRatePrice }}</td>
          <td>税率(%)</td>
          <td>{{ formData.documentRate }}</td>
        </tr>
        <tr>
          <td>税额（元）</td>
          <td>{{ formData.taxAmount }}</td>
          <td>费用类型</td>
          <td>
            {{ filterDictText(costTypeList,formData.feeType) }}
          </td>
        </tr>
        <tr>
          <td>退款状态</td>
          <td>
            {{ filterDictText(backStatusList,formData.backStatus) }}
          </td>
          <td>退款时间</td>
          <td>
            {{ formData.accountingTime && $Moment(formData.accountingTime).format(momentDateTime) }}
          </td>
        </tr>
        <tr>
          <td>红冲状态</td>
          <td>
            {{ filterDictText(backInvoicestatusList,formData.backInvoicestatus) }}
          </td>
          <td>红冲时间</td>
          <td>
            {{ formData.backInvoiceRequestTime && $Moment(formData.backInvoiceRequestTime).format(momentDateTime) }}
          </td>
        </tr>
        <tr>
          <td>开票人</td>
          <td>{{ formData.invoiceUsername }}</td>
          <td>发票号码</td>
          <td>{{ formData.invoiceNo }}</td>
        </tr>
        <tr>
          <td>备注</td>
          <td colspan="3">
            {{ formData.remark }}
          </td>
        </tr>
      </table>
    </section>
    <!--操作按钮-->
    <div class="but_footer">
      <div class="but_footer-h">
        <div class="but_footer-but">
          <el-button @click="back">
            关闭
          </el-button>
        </div>
      </div>
    </div>
  </div>
</template>
<script>
/* 接口*/
import { queryBackPriceDetailByFeeDocId } from '@api/fee/docfee'
/* 混合开发方法-参数字段*/
import { TenderFeeGroupMixin } from '../mixins/tenderFeeGroupMixin'
export default {
  name: 'TenderFeeRefundInvoiceDetail',
  components: {
  },
  mixins: [TenderFeeGroupMixin],
  data() {
    return {
      formData: {
        department: '', // 业务部门
        documentPrice: 0, // 开票金额
        feeType: '', // 费用类型: 00资格预审文件费 01招标文件费
        packName: '', // 标段名称
        packNo: '', // 标段编号
        supplierName: '', // 投标人
        tenderManager: '', // 项目经理
        tenderName: '', // 项目名称
        tenderNo: '', // 项目编号
        accountingTime: '', // 到账时间
        address: '', // 地址
        bank: '', // 开户行
        documentRate: '', // 标书费开票税率（%）
        invoiceNo: '', // 发票编号
        invoiceUsername: '', // 开票人名称
        noTaxRatePrice: 0, // 不含税金额
        number: '', // 银行账号
        payMode: '', // 支付方式：00易宝支付 01支付宝02中金 04支付微信
        phone: '', // 电话
        projectIndustryName: '', // 项目行业分类
        taxAmount: 0, // 税额
        taxpayerIdentificationNumber: '', // 纳税人识别号
        uniteCode: '', // 联行号
        backInvoiceRequestTime: '', // 红冲开票发起接口请求时间
        backInvoicestatus: '', // 接口红冲开票状态: 00 未红冲开票 01已经红冲开票 02 红冲开票失败 03 红冲开票申请中
        backStatus: '', // 接口实际退款状态 :00,未发起请求，01，退款成功,02 退款失败, 03 退款申请中
        remark: '' // 备注
      }
    }
  },
  created() {
    // 根据标书费id查看退款详情
    this.getBackPriceDetail()
  },
  methods: {
    // 根据标书费id查看退款详情
    getBackPriceDetail() {
      const feeDocId = this.$route.params.feeDocId // 标书费id
      queryBackPriceDetailByFeeDocId(feeDocId).then(res => {
        this.formData = res.data
      })
    },
    // 返回
    back() {
      this.$router.push({
        path: '/fee/tenderFeeRefundInvoice',
        name: 'TenderFeeRecordInvoiceList'
      })
    }
  }
}
</script>
<style lang="less" scoped>

</style>
