export const search = [
  // 账号名称
  {
    prop: 'accountName',
    label: '账号名称',
    type: 'input' as const,
    placeholder: '请输入账号',
    width: '240px',
  },
  // 开始时间
  {
    prop: 'startTime',
    label: '注册开始时间',
    placeholder: '请选择注册开始时间',
    type: 'date' as const,
    dateType: 'date' as const, // 时间范围选择器
    valueFormat: 'YYYY-MM-DD',
    width: '280px',
  },
  // 结束时间
  {
    prop: 'endTime',
    label: '注册结束时间',
    placeholder: '请选择注册结束时间',
    type: 'date' as const,
    dateType: 'date' as const, // 时间范围选择器
    valueFormat: 'YYYY-MM-DD',
    width: '280px',
  },
  {
      prop: 'status',
      label: '状态',
      type: 'select' as const,
      placeholder: '选择状态',
      width: '80px',
      options: [
          { label: '正常', value: 1 },
          { label: '封禁', value: 2 }
      ],
  }
]

export const tableColumns = [
  // 账号名称
  { label: '账号名称', prop: 'accountName', width: '160', align: 'center' as const },
  { label: '邮箱', prop: 'email', align: 'center' as const, width: '160px' },
  { label: '手机号', prop: 'mobile', align: 'center' as const, width: '180' },
  // 账号id
  { prop: 'userId', label: '账号id', width: '220', align: 'center' as const },
  // 状态
  { prop: 'statusName', label: '状态', align: 'center' as const },
  // 账号角色
  { prop: 'role', label: '账号角色', width: '100', align: 'center' as const },
  // 账号数量
  { prop: 'accountQty', label: '账号数量', width: '120', align: 'center' as const },
  { prop: 'amount', label: '资金', align: 'center' as const, isNumber: true, width: '120' },
  // 点差分配比例
  { prop: 'marginRatio', label: '点差分配比例', slotName: 'marginRatio', width: '140', align: 'center' as const },
  // 手续费分成比例
  { prop: 'commissionRatio', label: '手续费分成比例', slotName: 'commissionRatio', width: '140', align: 'center' as const },
  // 注册时间
  { prop: 'createTime', label: '注册时间', sortable: false, width: '240', align: 'center' as const },
  // 操作
  { label: '操作', slotName: 'action', width: '220', fixed: 'right' as const }
]

// 点差表格配置
export const marginRatioTableColumns = [
  // 品种名称
  { prop: 'varietyName', label: '名称', align: 'center' as const },
  // 品种编号
  { prop: 'varietyCode', label: '编号', align: 'center' as const },
  // 可分配点差
  { prop: 'pointDifference', label: '可分配点差', align: 'center' as const },
  // 已分配点差
  { prop: 'assignedPointDifference', label: '已分配点差', align: 'center' as const, slotName: 'assignedPointDiff' },
]

// 手续费分成比例form配置
export const commissionRatioFormItem = [
  // 手续费分成比例
  { prop: 'commissionRatio', label: '手续费分成比例', type: 'input' as const, placeholder: '请输入手续费分成比例', labelWidth: '140px' },
]