<template>
  <div>
    <!--区域专员待处理点数-->
    <data-table :api="api" :menuCode="menuId" :toolMenuFlag="false"
                :border="true" :stripe="true" :loadList="loadList"
                :handleFlag.sync="handleFlag" :showSelection="false" :queryParas="queryParas"
                :sourceData.sync="sourceData" :showPage="false"
                :loadCount.sync="loadCount" :columns="columns" :operateBtnLayout="operateBtnLayout">
    </data-table>
  </div>
</template>

<script>
import BasePage from '@/pages/basePage'
import * as format from '@/filters/index'
import mixin from '@/pages/mixin'
import { DataTable } from 'newepoch-components'
import tracemgrApi from '@/api/tracemgrApi'

export default {
  extends: new BasePage(),
  name: 'TaskStatisticsList',
  mixins: [mixin],
  components: {
    format,
    DataTable,
    tracemgrApi
  },
  data: function () {
    return {
      sourceData: [],
      row: {},
      operateBtnLayout: '',
      loadCount: 0,
      currentTotal: '',
      loadList: 'getList',
      showDetail: false,
      priority: '',
      enterpriseName: '',
      operationField: [],
      operationType: [],
      operationTime: '',
      createHistoryTime: '',
      createTime: '',
      item: {},
      queryParas: {
        pageIndex: 1,
        pageSize: 10
      },
      showOperation: true,
      selectedRows: [],
      handleFlag: true,
      columns: [
        {
          prop: 'taskType1',
          align: 'center',
          label: this.$i18n.messages[this.$i18n.locale].traceMgr.taskType,
          showOverflowTooltip: true,
          width: '200px'
        },
        {
          prop: 'waitHandleNum1',
          align: 'center',
          label: this.$i18n.messages[this.$i18n.locale].traceMgr.waitHandleNum,
          showOverflowTooltip: true,
          width: 150
        },
        {
          prop: 'taskType2',
          align: 'center',
          width: 150,
          showOverflowTooltip: true,
          label: this.$i18n.messages[this.$i18n.locale].traceMgr.taskType
        },
        {
          prop: 'waitHandleNum2',
          align: 'center',
          label: this.$i18n.messages[this.$i18n.locale].traceMgr.waitHandleNum,
          showOverflowTooltip: true,
          width: '200px'
        },
        {
          prop: 'taskType3',
          align: 'center',
          label: this.$i18n.messages[this.$i18n.locale].traceMgr.taskType,
          showOverflowTooltip: true,
          width: 150
        },
        {
          prop: 'waitHandleNum3',
          align: 'center',
          label: this.$i18n.messages[this.$i18n.locale].traceMgr.waitHandleNum,
          showOverflowTooltip: true,
          width: '150px'
        }
      ]
    }
  },
  computed: {
    api () {
      return tracemgrApi['taskStatisticsList']
    }
  },
  mounted () {
    this.handleFilter()
  },
  handleFilter () {
    this.loadCount = this.loadCount + 1
  },
  methods: {
  }
}
</script>
