using System; namespace RecruitmentDAL.DTO.JobAdSpend { // TJOBADSPEND — one row per spend record for a JobRequisition x job-board channel. A // requisition posted to N boards gets N rows; a re-post/top-up on the same board is a new row // rather than an update, so spend history per board is never overwritten. See // DB/Migrations/20260905_Recruitment_Phase6_JobAdSpend_SqlServer.sql's header for why this is // recorded as a standalone save (not wired into any GOP publish transaction — no such // per-channel publish transaction exists yet in this module) and why CHANNELTYPE mirrors // MCANDIDATE.SOURCE / TAPPLICATION.APPLICATIONSOURCE's existing 1-6 enum. public class JobAdSpendDTO { #region PrivateMembers private int jobadspendid; private int jobrequisitionid = -1; // FK TJOBREQUISITION private byte channeltype = 2; // 1=Website 2=JobPortal 3=Agency 4=Referral 5=Internal 6=Direct/Manual private string? jobboardname; // e.g. "LinkedIn", "Indeed", "Naukri", "Agency-XYZ" private DateTime posteddate = DateTime.UtcNow; private decimal spendamount; private string currencycode = "USD"; #region Standard private short sortorder; private byte status = 1; private short version; private int tenantid; #endregion #region Base private int createdbyid; private DateTime createdon; private string? createdbyname; private int modifiedbyid; private DateTime modifiedon; private string? modifiedbyname; #endregion #endregion #region PublicMembers public int JobAdSpendId { get { return jobadspendid; } set { jobadspendid = value; } } public int JobRequisitionId { get { return jobrequisitionid; } set { jobrequisitionid = value; } } public byte ChannelType { get { return channeltype; } set { channeltype = value; } } public string? JobBoardName { get { return jobboardname; } set { jobboardname = value; } } public DateTime PostedDate { get { return posteddate; } set { posteddate = value; } } public decimal SpendAmount { get { return spendamount; } set { spendamount = value; } } public string CurrencyCode { get { return currencycode; } set { currencycode = value; } } #region Standard public short SortOrder { get { return sortorder; } set { sortorder = value; } } public byte Status { get { return status; } set { status = value; } } public short Version { get { return version; } set { version = value; } } public int TenantId { get { return tenantid; } set { tenantid = value; } } #endregion #region Base public int CreatedById { get { return createdbyid; } set { createdbyid = value; } } public DateTime CreatedOn { get { return createdon; } set { createdon = value; } } public string? CreatedByName { get { return createdbyname; } set { createdbyname = value; } } public int ModifiedById { get { return modifiedbyid; } set { modifiedbyid = value; } } public DateTime ModifiedOn { get { return modifiedon; } set { modifiedon = value; } } public string? ModifiedByName { get { return modifiedbyname; } set { modifiedbyname = value; } } #endregion #endregion } // CHANNELTYPE — a byte "enum" per this module's established convention (documented via header // comments/static classes rather than a real C# enum — e.g. BgVerificationCheckType, // ApplicationDTO.ApplicationSource). Deliberately the SAME value set as MCANDIDATE.SOURCE / // TAPPLICATION.APPLICATIONSOURCE so JobAdSpendPerformanceQB can correlate spend back to // applications by channel. public static class JobAdSpendChannelType { public const byte Website = 1; public const byte JobPortal = 2; public const byte Agency = 3; public const byte Referral = 4; public const byte Internal = 5; public const byte DirectManual = 6; } }