<template>
  <div class="">
    <toolbar @on-filter="filterData" @on-reset="filterData" />

    <base-table
      class="m-10 bg-w p-20 br-10"
      :columns="columns"
      :items="items"
      :pagination="pagination"
      :page-change="pageChange"
    />
  </div>
</template>

<script>
import toolbar from './toolbar';
import mxFilterList from '@/mixins/filterList';
import { getPage, delItem } from '@/api/points/detail';

export default {
  name: 'PointsDetail',

  components: { toolbar },

  mixins: [
    mxFilterList({
      fetchList: getPage // 在下方data再声明一个 fetchList: iGetList 同等效果
    })
  ],

  data() {
    return {
      columns: [
        {
          key: 'accountId',
          name: '用户ID',
          width: this.$col.m
        },
        // {
        //   key: 'region',
        //   name: '昵称',
        //   width: '180'
        // },
        // {
        //   key: 'region',
        //   name: '手机号',
        //   width: '120'
        // },
        {
          key: 'scene',
          name: '场景',
          width: this.$col.b
        },
        {
          key: 'displayText',
          name: '展示文案',
          minWidth: this.$col.b
        },
        {
          key: 'createAt',
          name: '时间',
          width: this.$col.b
        }
      ]
    };
  }
};
</script>

<style type="scss" scoped></style>
