import { Type } from 'class-transformer';
import { IsArray, IsString, IsOptional, IsISO8601, IsDate, IsInt } from 'class-validator';

export class AssignToClientDto {
  @IsOptional()
  @IsString()
  lotNumber?: string;

  @IsOptional()
  @IsString()
  clientId?: string;

  @IsOptional()
  @IsString()
  driverId?: string;

  @IsOptional()
  @IsString()
  driverName?: string;

  @IsOptional()
  @IsString()
  vehicleId?: string;

  @IsOptional()
  @IsString()
  vehicleNumber?: string;

  @IsArray()
  @IsOptional()
  cylinderIds?: string[];

  @IsArray()
  @IsOptional()
  cylinderRfids?: string[];

  @IsDate()
  @Type(() => Date)
  @IsOptional()
  challanDate?: Date;

  @IsDate()
  @Type(() => Date)
  @IsOptional()
  dispatchDate?: Date;

  @IsOptional()
  @IsInt()
  @Type(() => Number)
  is_trial?: number;
}
