<template>
  <div>
    <div style="text-align:right;padding:5px 10px ">
      <el-button size="mini" type="primary">新增</el-button>
    </div>
    <el-table v-loading='loading' :tableData='tableData' border>
      <el-table-column align="center" label="盘点项目名称"></el-table-column>
      <el-table-column align="center" label="库区存放位置"></el-table-column>
      <el-table-column align="center" label="创建人"></el-table-column>
      <el-table-column align="center" label="创建时间"></el-table-column>
      <el-table-column align="center" label="完成时间"></el-table-column>
      <el-table-column align="center" label="档案盒数量"></el-table-column>
      <el-table-column align="center" label="借出状态"></el-table-column>
      <el-table-column align="center" label="操作"></el-table-column>
    </el-table>
    <el-pagination @current-change="handleCurrentChange" @size-change="handleSizeChange"
      layout="total, prev, pager, next, sizes" :page-size="pagination.pageSize" :page-sizes="[10, 20, 30, 50]"
      :current-page="pagination.pageNum" :total="pagination.total">
    </el-pagination>
  </div>
</template>
<script>
  export default {
    props: {
      loading: {
        type: Boolean,
        default: () => {},
      },
      tableData: {
        type: Array,
        default: () => [],
      },
      pagination: {
        type: Object,
        default: () => {},
      },
    },
    data() {
      return {

      }
    },
    methods: {
      handleCurrentChange(val) {
        this.pagination.pageNum = val;
        this.$emit("refreshTable");
      },
      handleSizeChange(val) {
        this.pagination.pageSize = val;
        this.pagination.pageNum = 1;
        this.$emit("refreshTable");
      },
    }
  }

</script>
<style lang='scss' scoped>

</style>
