Files
PortBlog.API/PortBlog.API/Models/ExperienceDto.cs
T
rajukottedi 5b7952877e Admin API refactor: claim-based resume CRUD & versioning
Major refactor of AdminController and related services to support full CRUD for candidate resume, projects, hobbies, skills, academics, experiences, certifications, and contact info, all using access token claims for candidate identity. Introduced AdminService and expanded IResumeRepository for granular entity management. Updated DTOs for upsert operations and date support. Improved API versioning (Asp.Versioning.Mvc), Swagger integration, and middleware setup. Added unit test project. Enhanced error handling, documentation, and mapping.
2026-02-15 05:27:35 +05:30

45 lines
1.4 KiB
C#

using PortBlog.API.Entities;
namespace PortBlog.API.Models
{
public class ExperienceDto
{
public int? ExperienceId { get; set; }
public string Title { get; set; } = string.Empty;
public string? Description { get; set; }
public string Company { get; set; } = string.Empty;
public string? Location { get; set; }
/// <summary>
/// Full start date for write operations (e.g. "2020-01-01").
/// </summary>
public DateTime? StartDate { get; set; }
/// <summary>
/// Full end date for write operations. Null means "Present".
/// </summary>
public DateTime? EndDate { get; set; }
/// <summary>
/// Read-only display value: start year (e.g. "2020"). Mapped from entity on read.
/// </summary>
public string StartYear { get; set; } = string.Empty;
/// <summary>
/// Read-only display value: end year (e.g. "2023" or "Present"). Mapped from entity on read.
/// </summary>
public string EndYear { get; set; } = string.Empty;
/// <summary>
/// Read-only display value: formatted period (e.g. "Jan 2020 - Mar 2023"). Mapped from entity on read.
/// </summary>
public string Period { get; set; } = string.Empty;
public ICollection<ExperienceDetailsDto> Details { get; set; } = new List<ExperienceDetailsDto>();
}
}