export type ReportFormat = 'word' | 'ppt' | 'pdf' | 'excel'

export type ReportItem = {
  id: string
  title: string
  classId: string
  className: string
  studentId: string
  studentName: string
  format: ReportFormat
  originalFileName: string
  filePath: string
  fileExtension: string
  templateId: string
  createdAt: string
  updatedAt: string
}

export type GenerateReportsInput = {
  templateId: string
  classId: string
  studentIds?: string[]
}

export type LoadReportsResponse =
  | {
      ok: true
      reports: ReportItem[]
    }
  | {
      ok: false
      message: string
    }

export type GenerateReportsResponse =
  | {
      ok: true
      reports: ReportItem[]
      skipped: Array<{ studentName: string; reason: string }>
    }
  | {
      ok: false
      message: string
    }

export type OpenReportResponse =
  | {
      ok: true
    }
  | {
      ok: false
      message: string
    }

export type DeleteReportResponse =
  | {
      ok: true
    }
  | {
      ok: false
      message: string
    }
