using Jiaowu.Api.Domain.Academic;

namespace Jiaowu.Api.Infrastructure.OfficialDocuments;

public sealed record OfficialDocumentSnapshot(
    string InstitutionName,
    string IssuingOffice,
    string DocumentNumber,
    OfficialDocumentType Type,
    DateTime IssuedAt,
    string IssuedByName,
    string? Purpose,
    OfficialStudentSnapshot Student,
    IReadOnlyList<OfficialTranscriptRow> Grades,
    decimal TotalCredits,
    decimal EarnedCredits,
    decimal? GradePointAverage);

public sealed record OfficialStudentSnapshot(
    string StudentNumber,
    string Name,
    string Gender,
    string CollegeName,
    string MajorName,
    string ClassName,
    int EnrollmentYear,
    DateOnly EnrollmentDate,
    string Status);

public sealed record OfficialTranscriptRow(
    string AcademicTerm,
    string CourseCode,
    string CourseName,
    decimal Credits,
    decimal? Score,
    decimal? GradePoint,
    string ExamStatus);

public sealed record GeneratedOfficialDocument(
    byte[] Content,
    string Sha256);
