import { IsOptional, IsString, IsIn, IsDateString, IsMongoId } from 'class-validator';

export class FilterInvoicesDto {
    @IsOptional()
    @IsString()
    search?: string;

    @IsOptional()
    @IsMongoId()
    classId?: string;

    @IsOptional()
    @IsMongoId()
    studentId?: string;

    @IsOptional()
    @IsString()
    @IsIn(['pending', 'paid', 'partial'])
    status?: string;

    @IsOptional()
    @IsDateString()
    dateFrom?: string;

    @IsOptional()
    @IsDateString()
    dateTo?: string;

    @IsOptional()
    @IsString()
    academicYearId?: string;
}
