import type { TableConfig } from '../types'

export const vistaResumenIngresosPorComercioConfig: TableConfig = {
  name: 'vista_resumen_ingresos_por_comercio',
  table: 'vista_resumen_ingresos_por_comercio',
  primaryKey: 'id',
  defaultSelect: '*',
  transforms: {
    // Map fecha to created_at for consistency
    serializeRow: (row: any) => ({
      ...row,
      created_at: row.fecha || row.created_at
    })
  }
}