import { ApiProperty } from '@nestjs/swagger';
import { IsIn, IsOptional } from 'class-validator';
import { TicketCategory } from '../entities/ticket.entity';

export class UpdateTicketDto {
  @ApiProperty({ example: true, required: false })
  @IsOptional()
  isClosed?: boolean;

  @ApiProperty({ example: true, required: false })
  @IsOptional()
  isReaded?: boolean;

  @ApiProperty({ enum: TicketCategory, required: false })
  @IsOptional()
  @IsIn(Object.values(TicketCategory))
  category?: TicketCategory;
}
