using TakeoutSaaS.Shared.Abstractions.Entities;

namespace TakeoutSaaS.Domain.Merchants.Entities;

/// <summary>
/// 商户变更日志。
/// </summary>
public sealed class MerchantChangeLog : MultiTenantEntityBase
{
    /// <summary>
    /// 商户标识。
    /// </summary>
    public long MerchantId { get; set; }

    /// <summary>
    /// 变更字段名。
    /// </summary>
    public string FieldName { get; set; } = string.Empty;

    /// <summary>
    /// 变更前值。
    /// </summary>
    public string? OldValue { get; set; }

    /// <summary>
    /// 变更后值。
    /// </summary>
    public string? NewValue { get; set; }

    /// <summary>
    /// 变更类型。
    /// </summary>
    public string ChangeType { get; set; } = "Update";

    /// <summary>
    /// 变更人 ID。
    /// </summary>
    public long? ChangedBy { get; set; }

    /// <summary>
    /// 变更人名称。
    /// </summary>
    public string? ChangedByName { get; set; }

    /// <summary>
    /// 变更原因。
    /// </summary>
    public string? ChangeReason { get; set; }
}
