<template>
  <div id="intelligentDockingFinishList">
    <el-row>
      <el-col :span="24">
        <el-table ref="debtTable" :data="debtTable" style="width: 100%" border>
          <el-table-column type="index" label="序号" width="50" align="center"> </el-table-column>
          <!--<el-table-column property="intelligent.company_name" label="企业名称" align="center"> </el-table-column>-->
          <el-table-column label="企业名称" align="center">
            <template slot-scope="scope">
              <span class="hand" @click="$router.push({ path: '/intelligentDocking/intelligentDockingFinishDetail', query: { intelligentId: scope.row.intelligentId } })">{{ scope.row.intelligent.company_name}}</span>
            </template>
          </el-table-column>

          <el-table-column property="intelligent.money" label="融资金额(万元)" align="center"> </el-table-column>
          <!--<el-table-column label="利率范围" align="center">-->
            <!--<template slot-scope="scope">-->
              <!--<span style="margin-left: 10px">{{ scope.row.intelligent.mongey_min_rate }}%~{{ scope.row.intelligent.mongey_max_rate }}%</span>-->
            <!--</template>-->
          <!--</el-table-column>-->
          <el-table-column label="当前状态" align="center">
            <template slot-scope="scope">
              <span style="margin-left: 10px">{{
                scope.row.creditStatus == '0'
                  ? '已接单'
                  : scope.row.creditStatus == '1'
                  ? '已放款'
                  : scope.row.creditStatus == '2'
                  ? '已审批'
                  : scope.row.creditStatus == '3'
                  ? '已拒绝'
                  : ' '
              }}</span>
            </template>
          </el-table-column>
          <el-table-column fixed="right" label="操作" align="center">
            <template slot-scope="scope">
              <el-button
                @click="$router.push({ path: '/intelligentDocking/intelligentDockingFinishDetail', query: { intelligentId: scope.row.intelligentId } })"
                type="text"
                icon="el-icon-view"
                title="查看详情"
              ></el-button>
            </template>
          </el-table-column>
        </el-table>
        <el-row class="page">
          <el-pagination
            @size-change="handleSizeChange"
            @current-change="handleCurrentChange"
            :current-page="currentPage"
            :page-size="10"
            layout="total, prev, pager, next, jumper"
            :total="total"
          >
          </el-pagination>
        </el-row>
      </el-col>
    </el-row>
  </div>
</template>

<script>
export default {
  name: 'intelligentDockingFinishList',
  props: {
    debtTable: null,
    total: null,
  },
  components: {},
  data: () => ({
    currentPage: 1,
  }),
  created() {},
  computed: {},
  methods: {
    handleSizeChange(val) {
      console.log(`每页 ${val} 条`);
    },
    handleCurrentChange(val) {
      this.$emit('pagechange', { skip: val });
    },
  },
};
</script>

<style lang="less" scoped>
.page {
  text-align: center;
  padding: 15px 0;
}
</style>
