namespace JobTrackerApi.Models; // Append-only evidence of what the user sent for an application. The snapshot owns copies of the // rendered CV, its source data, the cover letter, application material and attachment bytes, so // later edits to the live workspace cannot rewrite submission history. public sealed class SubmittedApplicationPackage { public int Id { get; set; } public string OwnerUserId { get; set; } = string.Empty; public int JobApplicationId { get; set; } public JobApplication? JobApplication { get; set; } public int Version { get; set; } public int? CvVariantId { get; set; } public string? CvVariantName { get; set; } public int? CvVariantVersion { get; set; } public string? CvThemeId { get; set; } public string? CvSettingsJson { get; set; } public string? CareerProfileJson { get; set; } public string? RenderedCvHtml { get; set; } public string? CoverLetterText { get; set; } public string ApplicationMaterialJson { get; set; } = "{}"; public DateTimeOffset CreatedAtUtc { get; set; } = DateTimeOffset.UtcNow; public List Attachments { get; set; } = new(); } public sealed class SubmittedPackageAttachment { public int Id { get; set; } public int SubmittedApplicationPackageId { get; set; } public SubmittedApplicationPackage? Package { get; set; } public string FileName { get; set; } = string.Empty; public string FileType { get; set; } = string.Empty; public string? Purpose { get; set; } public long FileSize { get; set; } public string Sha256 { get; set; } = string.Empty; public string FilePath { get; set; } = string.Empty; }