import { RecordDto } from "./userRecordsDto";

// RecordContentDto stays the same
export interface RecordContentDto {
  id: string;
  subject: string;
}

// New: Name object
export interface UserNameDto {
  am: string;
  en: string;
}

// New: UserDto
export interface UserDto {
  id: string;
  name: UserNameDto;
  username: string;
  email: string;
}

// New: EmployeePositionDto
export interface EmployeePositionDto {
  id: string;
  employeeId: string;
  positionId: string;
}

// New: PositionHolderDto — represents the full response you showed
export interface PositionHolderDto {
  id: string;
  name: string | null;
  user: UserDto;
  employeePositions: EmployeePositionDto[];
}

// Existing AssignRecordDto, no need to change unless you now need to relate it to these positions
export interface AssignRecordDto {
  recordBoxes: any;
  recordBoxId: any;
  createdAt: string;
  id: string;
  status: string;
  isRead?: boolean;
  record: RecordDto;
  content: [id: string, subject: string];
}

export interface ReAssignPositionDto {
  positionId?: string;
  employeePositionId?: string;
  employeeId?: string;
}

export interface ReAssignRecordPayload {
  incomingInstanceId: string;
  recordId: string;
  comment?: string;
  positions: ReAssignPositionDto[];
}

export interface AcceptIncomingRecordPayload {
  incomingInstanceId: string;
  status: string;
  comment?: string;
}

export interface AssignCCPayload {
  recordCCId: string;
  recordId: string;
  comment: string;
  positions: {
    positionId: string;
    employeePositionId: string;
  }[];
}

export interface AssignIncomingRecordPayload {
  recordBoxId: string;
  recordId: string;
  employeePositionIds: string[];
  positionIds?: string[] | null;
  comment: string;
}

export interface PositionNameDto {
  am: string;
  en: string;
}

export interface PositionDto {
  createdAt: string;
  updatedAt: string;
  id: string;
  name: PositionNameDto;
  key: string;
  parentPositionId: string | null;
  unitId: string;
  organizationId: string;
  projectId: string | null;
  positionTypeId: string;
}
