<template>
  <div class="comom-title">
    <div class="title">重点人发掘情况</div>
  </div>
  <div class="comom-cnt" id="fjfk">
    <MyTable
      @changePage="changePage"
      customClass="zdy_bkcz_table"
      :tableData="pageData.tableData"
      :tableColumn="pageData.tableColumn"
      :tableHeight="pageData.tableHeight"
      :key="pageData.keyCount"
      :tableConfiger="pageData.tableConfiger"
    >
      <template #tp="{ row }">
        <img width="30" src="@/assets/images/icon100.png" alt="" />
      </template>
    </MyTable>
  </div>
</template>
    
<script setup>
import MyTable from "@/components/aboutTable/DarkTable.vue";
import { reactive, onMounted } from "vue";
const pageData = reactive({
  tableData: [
    {
      tp: "https://example.com/photo1.jpg",
      xm: "张三",
      xb: "男",
      sfzh: "330102199001011234",
      gkyy: "抢劫xxxxx"
    },
    {
      tp: "https://example.com/photo2.jpg",
      xm: "李四",
      xb: "女",
      sfzh: "330102199203034567",
      gkyy: "抢劫xxxxx"
    },
    {
      tp: "https://example.com/photo3.jpg",
      xm: "王五",
      xb: "男",
      sfzh: "330102199505057890",
      gkyy: "抢劫xxxxx"
    },
    {
      tp: "https://example.com/photo3.jpg",
      xm: "王五",
      xb: "男",
      sfzh: "330102199505057890",
      gkyy: "抢劫xxxxx"
    },
    {
      tp: "https://example.com/photo3.jpg",
      xm: "王五",
      xb: "男",
      sfzh: "330102199505057890",
      gkyy: "抢劫xxxxx"
    },
    {
      tp: "https://example.com/photo3.jpg",
      xm: "王五",
      xb: "男",
      sfzh: "330102199505057890",
      gkyy: "抢劫xxxxx"
    }
  ],
  keyCount: 0,
  tableConfiger: {
    loading: false,
    rowHieght: 61,
    haveControls: false,
    showSelectType: "null",
    showIndex: false,
    stripe: true
  },
  total: 0,
  pageConfiger: {
    pageSize: 20,
    pageNum: 1
  }, //分页
  tableColumn: [
    { label: "照片", prop: "tp", showSolt: true },
    { label: "姓名", prop: "xm", showOverflowTooltip: true },
    { label: "性别", prop: "xb", showOverflowTooltip: true },
    { label: "身份证号码", prop: "sfzh", showOverflowTooltip: true },
    { label: "管控原因", prop: "gkyy", showOverflowTooltip: true }
  ]
});

onMounted(() => {
  tabHeightFn();
});

const changePage = () => {
  console.log("触底加载==========");
};

// 表格高度计算
const tabHeightFn = () => {
  pageData.tableHeight =  document.getElementById('fjfk').offsetHeight - 10;
    window.onresize = function () {
      tabHeightFn();
    };
};

</script>
    
    
<style lang="scss" scoped>
@import "@/assets/css/homeScreen.scss";
::v-deeep .comom-title {
  background: url("~@/assets/images/bg18.png") no-repeat center center;
  background-size: 100% 100%;
}
::v-deep .el-table td.el-table__cell {
  color: #ffffff;
}

::v-deep
  .el-table--striped
  .el-table__body
  tr.el-table__row--striped
  td.el-table__cell {
  background: rgba(0, 61, 130, 0.75);
}
</style>
<style lang="scss">

.zdy_bkcz_table td.el-table__cell {
  color: #ffffff !important;
}
.zdy_bkcz_table th.el-table__cell {
  color: #ffffff !important;
  font-size: 15px;
}
</style>