using DS.Module.Core; using FluentValidation; namespace DS.WMS.Core.Fee.Dtos; /// /// 币别信息请求实体 /// public class FeeCurrencyReq { /// /// 主键Id /// public long Id { get; set; } /// /// 币别代码 /// public string CodeName { get; set; } /// /// 币别名称 /// public string Name { get; set; } /// /// 描述 /// public string Description { get; set; } /// /// 财务软件代码 /// public string FinanceSoftCode { get; set; } /// /// 默认对人民币汇率 /// public decimal? DefaultRate { get; set; } /// /// 状态 0 启用 1 禁用 /// public StatusEnum? Status { get; set; } = StatusEnum.Enable; /// /// 备注 /// public string Note { get; set; } = ""; } /// /// 验证 /// public class FeeCurrencyReqValidator : AbstractValidator { /// /// 构造函数 /// public FeeCurrencyReqValidator() { this.RuleFor(o => o.CodeName) .NotEmpty().WithName("币别代码"); this.RuleFor(o => o.Name) .NotEmpty().WithName("币别名称"); } }