style: 命令不可变化与规范补充

This commit is contained in:
2025-12-02 12:09:46 +08:00
parent 3e01943727
commit 541b75ecd8
13 changed files with 217 additions and 186 deletions

View File

@@ -7,45 +7,45 @@ namespace TakeoutSaaS.Application.App.Merchants.Commands;
/// <summary>
/// 更新商户命令。
/// </summary>
public sealed class UpdateMerchantCommand : IRequest<MerchantDto?>
public sealed record UpdateMerchantCommand : IRequest<MerchantDto?>
{
/// <summary>
/// 商户 ID。
/// </summary>
public long MerchantId { get; set; }
public long MerchantId { get; init; }
/// <summary>
/// 品牌名称。
/// </summary>
public string BrandName { get; set; } = string.Empty;
public string BrandName { get; init; } = string.Empty;
/// <summary>
/// 品牌简称。
/// </summary>
public string? BrandAlias { get; set; }
public string? BrandAlias { get; init; }
/// <summary>
/// Logo 地址。
/// </summary>
public string? LogoUrl { get; set; }
public string? LogoUrl { get; init; }
/// <summary>
/// 品类。
/// </summary>
public string? Category { get; set; }
public string? Category { get; init; }
/// <summary>
/// 联系电话。
/// </summary>
public string ContactPhone { get; set; } = string.Empty;
public string ContactPhone { get; init; } = string.Empty;
/// <summary>
/// 联系邮箱。
/// </summary>
public string? ContactEmail { get; set; }
public string? ContactEmail { get; init; }
/// <summary>
/// 入驻状态。
/// </summary>
public MerchantStatus Status { get; set; }
public MerchantStatus Status { get; init; }
}