using System.ComponentModel.DataAnnotations;
using DS.Module.Core;
using FluentValidation;
using SqlSugar;
namespace DS.WMS.Core.Sys.Dtos;
///
/// 银行信息请求实体
///
public class BankReq
{
///
/// 主键Id
///
public long Id { get; set; }
///
/// 关联Id
///
public long LinkId { get; set; }
///
/// 代码
///
public string CodeName { get; set; }
///
/// 币别
///
public string Currency { get; set; }
///
/// 银行名称
///
public string BankName { get; set; }
///
/// 银行名称2
///
public string BankName2 { get; set; }
///
/// Desc:银行账户
///
public string BankAccountNo { get; set; }
///
/// Desc:户头名称
///
public string AccountName { get; set; }
///
/// 科目代码
///
public string SubjectCode { get; set; }
///
/// 财务软件代码
///
public string FinanceSoftCode { get; set; }
///
/// 是否默认 0否 1是
///
public bool IsDefault { get; set; } = false;
///
/// 排序
///
public int? OrderNo { get; set; } = 100;
///
/// 状态 0 启用 1 禁用
///
public StatusEnum? Status { get; set; } = StatusEnum.Enable;
///
/// 备注
///
public string Note { get; set; } = "";
}
///
/// 验证
///
public class BankReqValidator : AbstractValidator
{
///
/// 构造函数
///
public BankReqValidator()
{
this.RuleFor(o => o.CodeName)
.NotEmpty().WithName("银行代码");
// this.RuleFor(o => o.ColumnView)
// .NotEmpty().WithName("中文视图名");
}
}