<template>
  <div>
    <div class="sty">
      <el-page-header @back="goBack" content="详情"> </el-page-header>
    </div>
    <br />
    <br />
    <span>返利互转单</span>
    <el-divider></el-divider>
    <!-- 筛选条件 -->
    <div>
      <el-form label-width="100px" size="small" label-position="left">
        <el-row :gutter="20">
          <el-col :xs="24" :sm="12" :lg="6">
            <el-form-item label="返利互转单号" prop="">
              <el-input
                disabled
                v-model="detailList.id"
                placeholder="请输入"
              ></el-input>
            </el-form-item>
          </el-col>
          <el-col :xs="24" :sm="12" :lg="6">
            <el-form-item label="单据日期" prop="">
              <el-input
                disabled
                v-model="detailList.theTime"
                placeholder="请输入"
              ></el-input>
            </el-form-item>
          </el-col>
          <el-col :xs="24" :sm="12" :lg="6">
            <el-form-item label="制单人" prop="">
              <el-input disabled placeholder="请输入"></el-input>
            </el-form-item>
          </el-col>
          <el-col :xs="24" :sm="12" :lg="6">
            <el-form-item label="经销商编号" prop="">
              <el-input
                disabled
                v-model="detailList.customerNumber"
                placeholder="请输入"
              ></el-input>
            </el-form-item>
          </el-col>
          <el-col :xs="24" :sm="12" :lg="6">
            <el-form-item label="经销商名称" prop="">
              <el-input
                disabled
                v-model="detailList.customerName"
                placeholder="请输入"
              ></el-input>
            </el-form-item>
          </el-col>
          <el-col :xs="24" :sm="12" :lg="6">
            <el-form-item label="备注信息" prop="">
              <el-input
                disabled
                v-model="detailList.remark"
                placeholder="请输入"
              ></el-input>
            </el-form-item>
          </el-col>
          <el-col :xs="24" :sm="12" :lg="6">
            <el-form-item label="审核人" prop="">
              <el-input
                disabled
                v-model="detailList.examineBy"
                placeholder="请输入"
              ></el-input>
            </el-form-item>
          </el-col>
          <el-col :xs="24" :sm="12" :lg="6">
            <el-form-item label="审核日期" prop="">
              <el-input
                disabled
                v-model="detailList.examineTime"
                placeholder="请输入"
              ></el-input>
            </el-form-item>
          </el-col>
          <el-col :xs="24" :sm="12" :lg="6">
            <el-form-item label="关闭人" prop="">
              <el-input disabled placeholder="请输入"></el-input>
            </el-form-item>
          </el-col>
          <el-col :xs="24" :sm="12" :lg="6">
            <el-form-item label="关闭日期" prop="">
              <el-input disabled placeholder="请输入"></el-input>
            </el-form-item>
          </el-col>
        </el-row>
      </el-form>
    </div>
    <!-- 列表 -->
    <div class="mymain-container">
      <div class="table">
        <el-table
          v-loading="listLoading"
          :data="dataList"
          element-loading-text="Loading"
          border
          fit
          highlight-current-row
          stripe
        >
          <el-table-column
            label="序号"
            align="center"
            width="100"
            type="index"
            show-overflow-tooltip
          ></el-table-column>
          <el-table-column
            align="center"
            label="返利类型"
            prop="customerWalletName"
            min-width="160"
            show-overflow-tooltip
          ></el-table-column>
          <el-table-column
            align="center"
            label="返利金额"
            prop="amount"
            min-width="160"
            show-overflow-tooltip
          ></el-table-column>
          <el-table-column
            align="center"
            label="备注"
            prop="remark"
            min-width="160"
            show-overflow-tooltip
          ></el-table-column>
        </el-table>
      </div>
    </div>
  </div>
</template>

<script>
export default {
  props: {
    detailList: {
      type: Object,
      required: true,
    },
  },
  data() {
    return {
      dataList: [], // 列表数据
      searchForm: {}, //搜索表单
      listLoading: false, // 列表加载loading
    };
  },
  created() {
    this.dataList = [
      {
        customerWalletName: this.detailList.initiatorCustomerWalletName,
        remark: this.detailList.initiatorRemark,
        amount: -this.detailList.amount,
      },
      {
        customerWalletName: this.detailList.receiverCustomerWalletName,
        remark: this.detailList.receiverRemark,
        amount: this.detailList.amount,
      },
    ];
  },
  methods: {
    goBack() {
      this.$parent.showPage = 1;
    },
  },
};
</script>

<style>
</style>