import { ApiProperty, ApiPropertyOptional } from '@nestjs/swagger';

export class AssemblyMonitoringOverviewItemResponseDto {
  @ApiProperty({ type: String })
  model!: string;

  @ApiProperty({ type: String })
  serialNo!: string;

  @ApiProperty({ type: String })
  processName!: string;

  @ApiProperty({ type: String })
  startTime!: string;

  @ApiProperty({ type: Number })
  workerCount!: number;

  @ApiProperty({ type: Number })
  inputHours!: number;

  @ApiProperty({ type: [String] })
  workers!: string[];

  @ApiPropertyOptional({ type: String })
  status?: string;

  @ApiPropertyOptional({ type: String, nullable: true })
  endTime?: string | null;

  @ApiPropertyOptional({ type: Number, nullable: true })
  waitingDays?: number | null;
}

export class AssemblyMonitoringOverviewProcessResponseDto {
  @ApiProperty({ type: [AssemblyMonitoringOverviewItemResponseDto] })
  driveUnitAssembly!: AssemblyMonitoringOverviewItemResponseDto[];

  @ApiProperty({ type: [AssemblyMonitoringOverviewItemResponseDto] })
  corePumpAssembly!: AssemblyMonitoringOverviewItemResponseDto[];

  @ApiProperty({ type: [AssemblyMonitoringOverviewItemResponseDto] })
  legAssembly!: AssemblyMonitoringOverviewItemResponseDto[];

  @ApiProperty({ type: [AssemblyMonitoringOverviewItemResponseDto] })
  chassisModification!: AssemblyMonitoringOverviewItemResponseDto[];

  @ApiProperty({ type: [AssemblyMonitoringOverviewItemResponseDto] })
  mainAssembly!: AssemblyMonitoringOverviewItemResponseDto[];

  @ApiProperty({ type: [AssemblyMonitoringOverviewItemResponseDto] })
  chassisMount!: AssemblyMonitoringOverviewItemResponseDto[];

  @ApiProperty({ type: [AssemblyMonitoringOverviewItemResponseDto] })
  boomAssembly!: AssemblyMonitoringOverviewItemResponseDto[];

  @ApiProperty({ type: [AssemblyMonitoringOverviewItemResponseDto] })
  boomMount!: AssemblyMonitoringOverviewItemResponseDto[];

  @ApiProperty({ type: [AssemblyMonitoringOverviewItemResponseDto] })
  test!: AssemblyMonitoringOverviewItemResponseDto[];

  @ApiProperty({ type: [AssemblyMonitoringOverviewItemResponseDto] })
  accessory!: AssemblyMonitoringOverviewItemResponseDto[];

  @ApiProperty({ type: [AssemblyMonitoringOverviewItemResponseDto] })
  finalInspection!: AssemblyMonitoringOverviewItemResponseDto[];

  @ApiProperty({ type: [AssemblyMonitoringOverviewItemResponseDto] })
  confirmInspection!: AssemblyMonitoringOverviewItemResponseDto[];

  @ApiProperty({ type: [AssemblyMonitoringOverviewItemResponseDto] })
  painting!: AssemblyMonitoringOverviewItemResponseDto[];

  @ApiProperty({ type: [AssemblyMonitoringOverviewItemResponseDto] })
  body!: AssemblyMonitoringOverviewItemResponseDto[];

  @ApiProperty({ type: [AssemblyMonitoringOverviewItemResponseDto] })
  electric!: AssemblyMonitoringOverviewItemResponseDto[];

  @ApiProperty({ type: [AssemblyMonitoringOverviewItemResponseDto] })
  ladder!: AssemblyMonitoringOverviewItemResponseDto[];

  @ApiProperty({ type: [AssemblyMonitoringOverviewItemResponseDto] })
  turntable!: AssemblyMonitoringOverviewItemResponseDto[];

  @ApiProperty({ type: [AssemblyMonitoringOverviewItemResponseDto] })
  waterPump!: AssemblyMonitoringOverviewItemResponseDto[];

  @ApiProperty({ type: [AssemblyMonitoringOverviewItemResponseDto] })
  breakerAssembly!: AssemblyMonitoringOverviewItemResponseDto[];

  @ApiProperty({ type: [AssemblyMonitoringOverviewItemResponseDto] })
  idle!: AssemblyMonitoringOverviewItemResponseDto[];
}

export class AssemblyMonitoringInactiveWorkerResponseDto {
  @ApiProperty({ type: Number })
  employeeId!: number;

  @ApiProperty({ type: String })
  employeeName!: string;

  @ApiProperty({ type: String })
  departmentName!: string;
}

export class AssemblyMonitoringOverviewResponseDto {
  @ApiProperty({ type: AssemblyMonitoringOverviewProcessResponseDto })
  processes!: AssemblyMonitoringOverviewProcessResponseDto;

  @ApiProperty({ type: [AssemblyMonitoringInactiveWorkerResponseDto] })
  inactiveWorkers!: AssemblyMonitoringInactiveWorkerResponseDto[];
}
