using ERPCore.Domain.Enums;

namespace ERPCore.Domain.Entities;

/// <summary>The detailed Basic/Transport/Meal/OT/Late/No-Pay/Loan/EPF/ETF/Tax breakdown. Model: docs/12-BACKEND-HRM.md Part C.6.</summary>
public class PayrollLineComponent
{
    public int PayrollLineComponentId { get; set; }
    public int PayrollLineId { get; set; }
    public PayrollLine? PayrollLine { get; set; }
    public PayrollLineComponentCategory ComponentCategory { get; set; }
    /// <summary>Set only for structure-sourced Allowance/OtherDeduction lines; null for system-computed lines.</summary>
    public int? SalaryComponentId { get; set; }
    public SalaryComponent? SalaryComponent { get; set; }
    public string Label { get; set; } = string.Empty;
    public decimal Amount { get; set; }
    public int SortOrder { get; set; }
}
