// ============================================================
// Shared DTO fuer Owner-Operationen (Contact, Company, Deal)
// ============================================================

import { IsUUID, IsOptional, IsEnum } from 'class-validator';
import { ApiProperty, ApiPropertyOptional } from '@nestjs/swagger';

export enum OwnerRole {
  OWNER = 'OWNER',
  MEMBER = 'MEMBER',
  WATCHER = 'WATCHER',
}

export class AddOwnerDto {
  @ApiProperty({ format: 'uuid', description: 'User-ID des Owners (aus platform_core)' })
  @IsUUID()
  userId!: string;

  @ApiPropertyOptional({ enum: OwnerRole, default: OwnerRole.OWNER })
  @IsOptional()
  @IsEnum(OwnerRole)
  role?: OwnerRole;
}
