<!--
  @description: 抽取项目列表--直接指定
  @author: 徐媛媛
  @routerPath:/extractProject/expertProjectList
  @date: 2020-8-24 8:35:58
-->
<template>
  <div>
    <div>
      <el-table
        ref="smallTable"
        v-loading="loading"
        :data="adddata"
        class="tableLimit"
      >
        <el-table-column
          type="index"
          label="序号"
          width="50"
          align="center"
        />
        <el-table-column
          prop="tenderNo"
          align="center"
          label="抽取项目编号"
          min-width="160"
        />
        <el-table-column label="专家人数" prop="expertNum" width="70" align="center" />

        <el-table-column
          header-align="center"
          prop="tenderName"
          label="评标开始时间"
          min-width="160"
        />
        <el-table-column

          header-align="center"
          prop="tenderMethod"
          label="评标结束时间"
          width="160"
          align="center"
        />
        <el-table-column
          header-align="center"
          prop="managerName"
          label="创建时间"
          min-width="160"
        />
        <el-table-column label="审核状态" prop="auditStatus" min-width="90" align="center">
          <!-- <template slot-scope="{row}">{{ row.auditStatus | auditStatusTransform }}</template> -->
        </el-table-column>
        <el-table-column
          header-align="center"
          label="操作"
          min-width="160"
        >
          <template slot-scope="scope">
            <el-link
              v-if="scope.row.auditStatus==='01'"
              type="primary"
              @click.stop="intoProject(scope.row)"
            >
              [查看]]
            </el-link>
            <el-link
              type="primary"
              @click.stop="smokingProject(scope.row)"
            >
              补抽
            </el-link>
          </template>
        </el-table-column>
      </el-table>
    </div>
    <!--分页组件-->
    <pagination :pagination-data="paginationData" @change="loadData" />
  </div>
</template>

<script>
/* api*/
import { getExtractExpertApplyListByCreateUser
} from '@/api/expert/extractExpert/extractExpert'
/* 组件*/
import pagination from '@comp/common/pagination/pagination' // 分页组件
/* 混入公共方法*/
import { ListMixin } from '@/mixins/ListMixin'
export default {
  name: 'AddSelfTenderPlanList',
  components: {
    pagination
  },
  mixins: [ListMixin],
  props: {
    adddata: {
      type: Array,
      required: true
    }
  },
  data() {
    return {
      loading: false, // 表格loading
      addTableDatas: [] // 直接指定列表
    }
  },
  created() {

  },
  methods: {
    loadData() {
      const data = {
        page: 1,
        pageSize: 10,
        rakeType: '02'
      }
      getExtractExpertApplyListByCreateUser(data).then(res => {
        this.addTableDatas = res.data.records
      }).catch(res => {

      })
    },
    // 补抽
    smokingProject(row) {
      this.$router.push({
        name: 'extractProjectMakeUpContent',
        params: {
          id: row.id,
          type: '01'
        }
      })
    }
  }
}
</script>

<style lang="less" scoped>
</style>
