First Commit
This commit is contained in:
@@ -0,0 +1,51 @@
|
||||
using System;
|
||||
|
||||
namespace JobTrackerApi.Models
|
||||
{
|
||||
public class JobApplication
|
||||
{
|
||||
public int Id { get; set; }
|
||||
public string? OwnerUserId { get; set; }
|
||||
public string JobTitle { get; set; } = "";
|
||||
public int CompanyId { get; set; }
|
||||
public Company Company { get; set; } = null!;
|
||||
public string Status { get; set; } = "Applied";
|
||||
public DateTime DateApplied { get; set; } = DateTime.UtcNow;
|
||||
public string? Location { get; set; }
|
||||
public string? Salary { get; set; }
|
||||
public string? NextAction { get; set; }
|
||||
public DateTime? FollowUpAt { get; set; }
|
||||
public DateTime? FeedbackRequestedAt { get; set; }
|
||||
|
||||
// Attachment checklist
|
||||
public bool HasResume { get; set; } = false;
|
||||
public bool HasCoverLetter { get; set; } = false;
|
||||
public bool HasPortfolio { get; set; } = false;
|
||||
public bool HasOtherAttachment { get; set; } = false;
|
||||
|
||||
// Soft delete: hide from default queries without losing history.
|
||||
public bool IsDeleted { get; set; } = false;
|
||||
public DateTime? DeletedAt { get; set; }
|
||||
|
||||
public bool ResponseReceived { get; set; } = false;
|
||||
public DateTime? ResponseDate { get; set; }
|
||||
public string? Notes { get; set; }
|
||||
public string? CoverLetterText { get; set; }
|
||||
public string? JobUrl { get; set; }
|
||||
|
||||
// Imported job content
|
||||
public string? Description { get; set; }
|
||||
public string? TranslatedDescription { get; set; }
|
||||
public string? DescriptionLanguage { get; set; } // "en", "no", ...
|
||||
public string? Tags { get; set; } // JSON array string, e.g. ["Azure","Docker"]
|
||||
public DateTime? Deadline { get; set; }
|
||||
// Short summary generated at creation time and persisted to avoid repeated model calls.
|
||||
public string? ShortSummary { get; set; }
|
||||
|
||||
public List<Correspondence> Messages { get; set; } = new();
|
||||
public List<Attachment> Attachments { get; set; } = new();
|
||||
public List<JobEvent> Events { get; set; } = new();
|
||||
|
||||
public int DaysSince => ((ResponseReceived ? (ResponseDate ?? DateTime.UtcNow) : DateTime.UtcNow) - DateApplied.ToUniversalTime()).Days;
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user