import { Expose } from 'class-transformer';
import { IsBoolean, IsDateString, IsNumber, IsOptional } from 'class-validator';
import { BooleanTransform } from '../../../../middlewares/classTransformers/booleanTransform';
import { BaseTimeTrackingEntryRequestsVC } from './baseTimeTrackingEntryRequestsVC';

export class CreateTimeTrackingEntryRequestsVC extends BaseTimeTrackingEntryRequestsVC {
    @Expose()
    @IsOptional()
    @IsBoolean()
    @BooleanTransform(false)
    isRemoteWork?: boolean;

    @IsOptional()
    @IsNumber()
    @Expose()
    userId?: number;

    @IsOptional()
    @IsDateString()
    @Expose()
    time?: Date;

    @IsOptional()
    @IsDateString()
    @Expose()
    eventTime?: Date;
}
