using DS.Module.Core; using FluentValidation; namespace DS.WMS.Core.Sys.Dtos; /// /// 租户参数请求实体 /// public class TenantParamDataReq { /// /// 主键Id /// public long Id { get; set; } /// /// 参数类型Id /// public long ParamId { get; set; } /// /// 参数类型Code /// public string ParamCode { get; set; } /// /// 参数代码 /// public string ItemCode { get; set; } /// /// 参数名称 /// public string ItemName { get; set; } /// /// 排序 /// public int? OrderNo { get; set; } = 100; /// /// 状态 0 启用 1 禁用 /// public StatusEnum? Status { get; set; } = StatusEnum.Enable; /// /// 备注 /// public string Note { get; set; } = ""; } /// /// 验证 /// public class TenantParamDataReqValidator : AbstractValidator { /// /// 构造函数 /// public TenantParamDataReqValidator() { this.RuleFor(o => o.ItemCode) .NotEmpty().WithName("参数代码"); this.RuleFor(o => o.ItemName) .NotEmpty().WithName("参数名称"); } }