import {
  IsNotEmpty,
  IsEmail,
  IsDateString,
  IsOptional,
  IsNumber,
} from 'class-validator';

export class CreateUserDto {
  @IsNotEmpty()
  employeeId: string;

  @IsNotEmpty()
  firstName: string;

  @IsNotEmpty()
  lastName: string;

  @IsNotEmpty()
  @IsEmail()
  email: string;

  @IsNotEmpty()
  managerId: string;

  @IsNotEmpty()
  department: string;

  @IsNotEmpty()
  role: string;

  @IsNotEmpty()
  cohortId: string;

  @IsOptional()
  @IsDateString()
  validFrom?: Date;

  @IsOptional()
  @IsDateString()
  validTo?: Date;

  @IsOptional()
  @IsNumber()
  latestFlag?: number = 1;

  @IsOptional()
  @IsNumber()
  activeFlag?: number = 1;

  @IsOptional()
  @IsDateString()
  recordDateTime?: Date;

  @IsOptional()
  @IsNumber()
  companyTenantID?: number;
}
