<template>
  <div class="corePersonnel">
    <head-form
      title="判决文书"
      :form-data="formData"
      :query-params="queryParams"
      :total="tableDataTotal"
      :isExcel="false"
      @handle-search="handleSearch"
    />

    <tables
      :tableLoading="tableLoading"
      :tableData="tableData"
      :forData="forData"
      :tableDataTotal="tableDataTotal"
      :queryParams="queryParams"
      @handle-current-change="handleCurrentChange"
    />


  </div>
</template>

<script>
import mixin from '../mixins/mixin'
export default {
  name: 'Judgment',
  mixins: [mixin],
  components: {

  },
  data() {
    return {
      queryParams: {
        cid: 6034,
        pageNum: 1,
        pageSize: 10
      },
      forData: [
        {label: '案由', prop: 'causeAction', width: '240'},
        {label: '执行案号', prop: 'causeNo', width: '210'},
        {label: '身份', prop: 'role', width: '120'},
        {label: '当事人', prop: 'relatedCompanies', width: '240'},
        {label: '案件金额（元）', prop: 'subAmount', width: '140'},
        {label: '判决结果', prop: 'judgeresult', width: '508'},
        {label: '判决日期', prop: 'date', width: '95'},
      ],
      formData: [
        { type: 1, fieldName: 'causeAction', value: '', placeholder: '案由',
          options: [
            { name: '处罚类别1', value: '1' },
            { name: '处罚类别2', value: '2' },
            { name: '处罚类别3', value: '3' },
            { name: '处罚类别4', value: '4' }
          ]
        },
        { type: 1, fieldName: 'role', value: '', placeholder: '身份',
          options: [
            { name: '处罚类别1', value: '1' },
            { name: '处罚类别2', value: '2' },
            { name: '处罚类别3', value: '3' },
            { name: '处罚类别4', value: '4' }
          ]
        },
        { type: 2, fieldName: 'tiem', value: '', placeholder: '',startTime: 'dateFrom',endTime: 'dateTo', options: []},
        { type: 3, fieldName: 'keys', value: '', placeholder: '搜索关键字', options: []}
      ],
      //列表
      tableLoading:false,
      tableData:[],
      pageIndex:1,
      pageSize:10,
      tableDataTotal:0,
    }
  },
  created() {
    this.dataRegion()
  },
  computed: {

  },
  methods: {
    async dataRegion() {
      // await axios.post("https://files.jiansheku.com/file/json/common/dataRegion.json", {}, {
      //   headers: {
      //     'Content-Type': 'application/json'
      //   }
      // }).then(res => {
      //   if (res.data.code == 200) {
      //     console.log(res.data.data)
      //   }
      // })
    },
    handleQuery(params) {
      console.log(params)
    }
  }
}
</script>
<style lang="scss" scoped>
.corePersonnel{
  background: #ffffff;
  border-radius: 4px;
  padding: 16px;
  .query-box{
    margin: 10px 0 20px;
  }
}
</style>
