namespace MMDAL.DTO.StockValuation;
public class StockValuationRunDTO
{
public long StockValuationRunId { get; set; }
public int OUID { get; set; }
/// 0=Monthly, 1=Daily, 2=Perpetual-Rerun
public byte RunType { get; set; }
public string RunTypeName { get; set; } = string.Empty;
public DateOnly PeriodFrom { get; set; }
public DateOnly PeriodTo { get; set; }
public int? StoreId { get; set; }
public string StoreName { get; set; } = string.Empty;
public int? ItemId { get; set; }
public string ItemName { get; set; } = string.Empty;
public int? ItemCategoryId { get; set; }
public int? ItemSubCategoryId { get; set; }
public string ValuationMethods { get; set; } = string.Empty;
/// 0=Queued, 1=Running, 2=Done, 3=Failed
public byte Status { get; set; }
public string StatusName { get; set; } = string.Empty;
public DateTime? StartedAt { get; set; }
public DateTime? CompletedAt { get; set; }
public string? ErrorMessage { get; set; }
public int CreatedById { get; set; }
public DateTime CreatedOn { get; set; }
/// Duration in seconds, computed from StartedAt/CompletedAt.
public double? DurationSeconds { get; set; }
}