// interface colunm {
//   title: string;
//   dataIndex: string;
//   width?: number;
//   slots?: any;
//   sorter?: any;
//   children?: Array<colunm>;
//   ellipsis?: boolean;
//   sortDirections?: (string | false)[];
//   fixed?: string;
//   customRender?: any;
// }
import { ColumnProps } from 'ant-design-vue/es/table/interface';

// 员工绩效列表
export const TableColumnOfStuffPerformance: ColumnProps[] = [
  {
    title: '推广员',
    dataIndex: 'uname',
    fixed: 'left',
    width: 150,
  },
  {
    title: '成本合计(元)',
    dataIndex: 'cost_amount',
  },
  {
    title: '回本(元)',
    dataIndex: 'back_amount',
    sorter: (a: any, b: any) => a.back_amount - b.back_amount,
  },
  {
    title: '提现合计(元)',
    dataIndex: 'cash_withdrawal_amount',
  },
  {
    title: '提现(元)M+0',
    dataIndex: 'cash_withdrawal_amount',
    slots: { customRender: 'wm0' },
    width: 140
  },
  {
    title: '提现(元)M+1',
    dataIndex: 'cash_withdrawal_amount',
    slots: { customRender: 'wm1' },
    width: 140
  },
  {
    title: '提现(元)M+2',
    dataIndex: 'cash_withdrawal_amount',
    slots: { customRender: 'wm2' },
    width: 140
  },
  {
    title: '用户充值(元)',
    dataIndex: 'user_charge_amount_sum',
  },
  {
    title: '用户充值(元)M+0',
    dataIndex: 'cash_withdrawal_amount',
    slots: { customRender: 'cm0' },
    width: 140
  },
  {
    title: '用户充值(元)M+1',
    dataIndex: 'cash_withdrawal_amount',
    slots: { customRender: 'cm1' },
    width: 140
  },
  {
    title: '用户充值(元)M+2',
    dataIndex: 'cash_withdrawal_amount',
    slots: { customRender: 'cm2' },
    width: 140
  },
  {
    title: '操作',
    dataIndex: 'operation',
    slots: { customRender: 'operation' },
    fixed: 'right',
  },
]

// 员工绩效明细
export const TableColumnOfStuffDetail = [
  {
    title: '日期',
    dataIndex: 'date',
    fixed: 'left',
    width: 150
  },
  {
    title: '成本合计(元)',
    dataIndex: 'cost_amount',
  },
  {
    title: '回本(元)',
    dataIndex: 'back_amount',
    sorter: (a: any, b: any) => a.back_amount - b.back_amount,
  },
  {
    title: '提现合计(元)',
    dataIndex: 'cash_withdrawal_amount',
  },
  {
    title: '提现(元)M+0',
    dataIndex: 'cash_withdrawal_amount',
    slots: { customRender: 'wm0' },
    width: 140
  },
  {
    title: '提现(元)M+1',
    dataIndex: 'cash_withdrawal_amount',
    slots: { customRender: 'wm1' },
    width: 140
  },
  {
    title: '提现(元)M+2',
    dataIndex: 'cash_withdrawal_amount',
    slots: { customRender: 'wm2' },
    width: 140
  },
  {
    title: '用户充值(元)',
    dataIndex: 'user_charge_amount_sum',
  },
  {
    title: '用户充值(元)M+0',
    dataIndex: 'cash_withdrawal_amount',
    slots: { customRender: 'cm0' },
    width: 140
  },
  {
    title: '用户充值(元)M+1',
    dataIndex: 'cash_withdrawal_amount',
    slots: { customRender: 'cm1' },
    width: 140
  },
  {
    title: '用户充值(元)M+2',
    dataIndex: 'cash_withdrawal_amount',
    slots: { customRender: 'cm2' },
    width: 140
  },
]

