import { LeaveRequestViewDto } from '../dtos/leave-request-view.dto'; import { mapArchiveRowToView } from '../mappers/leave-requests-archive.mapper'; import { mapRowToView } from '../mappers/leave-requests.mapper'; import { LeaveRequestArchiveRow } from './leave-requests-archive.select'; import { LeaveRequestRow } from './leave-requests.select'; /** Active (table leave_requests) : proxy to base mapper */ export function mapRowToViewWithDays(row: LeaveRequestRow): LeaveRequestViewDto { return mapRowToView(row); } /** Archive (table leave_requests_archive) : proxy to base mapper */ export function mapArchiveRowToViewWithDays( row: LeaveRequestArchiveRow, email: string, employee_full_name?: string, ): LeaveRequestViewDto { return mapArchiveRowToView(row, email, employee_full_name!); }