|
|
|
using DS.Module.Core;
|
|
|
|
using FluentValidation;
|
|
|
|
using SqlSugar;
|
|
|
|
|
|
|
|
namespace DS.WMS.Core.Info.Dtos;
|
|
|
|
|
|
|
|
/// <summary>
|
|
|
|
/// 客户收发货人请求实体
|
|
|
|
/// </summary>
|
|
|
|
public class ClientShipperReq
|
|
|
|
{
|
|
|
|
/// <summary>
|
|
|
|
/// 主键Id
|
|
|
|
/// </summary>
|
|
|
|
public long Id { get; set; }
|
|
|
|
|
|
|
|
/// <summary>
|
|
|
|
/// 客户Id
|
|
|
|
/// </summary>
|
|
|
|
public long ClientId { get; set; }
|
|
|
|
|
|
|
|
/// <summary>
|
|
|
|
/// Desc:收发货人代码
|
|
|
|
/// </summary>
|
|
|
|
public string CodeName { get; set; }
|
|
|
|
|
|
|
|
/// <summary>
|
|
|
|
/// Desc:收发货人简称
|
|
|
|
/// </summary>
|
|
|
|
public string ShortName { get; set; }
|
|
|
|
|
|
|
|
/// <summary>
|
|
|
|
/// 收发货人名称
|
|
|
|
/// </summary>
|
|
|
|
public string Name { get; set; } = string.Empty;
|
|
|
|
|
|
|
|
/// <summary>
|
|
|
|
/// 地址
|
|
|
|
/// </summary>
|
|
|
|
public string? Address { get; set; }
|
|
|
|
|
|
|
|
/// <summary>
|
|
|
|
/// Desc:类型 下拉选择(Shipper-1,Consinee-2,Notifypaty-3,Agent-4)
|
|
|
|
/// </summary>
|
|
|
|
public int ShipperType { get; set; }
|
|
|
|
|
|
|
|
/// <summary>
|
|
|
|
/// 是否公共标识
|
|
|
|
/// </summary>
|
|
|
|
public bool IsPublic { get; set; } = false;
|
|
|
|
|
|
|
|
/// <summary>
|
|
|
|
/// Desc:详细信息
|
|
|
|
/// </summary>
|
|
|
|
public string ShortDetail { get; set; }
|
|
|
|
|
|
|
|
/// <summary>
|
|
|
|
/// Desc:联系人
|
|
|
|
/// </summary>
|
|
|
|
public string ATTN { get; set; }
|
|
|
|
|
|
|
|
/// <summary>
|
|
|
|
/// Desc:邮箱
|
|
|
|
/// </summary>
|
|
|
|
public string Email { get; set; }
|
|
|
|
|
|
|
|
/// <summary>
|
|
|
|
/// Desc:电话
|
|
|
|
/// </summary>
|
|
|
|
public string Tel { get; set; }
|
|
|
|
|
|
|
|
/// <summary>
|
|
|
|
/// Desc:公司代码
|
|
|
|
/// </summary>
|
|
|
|
public string CompanyNo { get; set; }
|
|
|
|
|
|
|
|
/// <summary>
|
|
|
|
/// 状态 0 启用 1 禁用
|
|
|
|
/// </summary>
|
|
|
|
public StatusEnum? Status { get; set; } = StatusEnum.Enable;
|
|
|
|
|
|
|
|
/// <summary>
|
|
|
|
/// 备注
|
|
|
|
/// </summary>
|
|
|
|
public string Note { get; set; } = "";
|
|
|
|
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
/// <summary>
|
|
|
|
/// 验证
|
|
|
|
/// </summary>
|
|
|
|
public class ClientShipperReqValidator : AbstractValidator<ClientShipperReq>
|
|
|
|
{
|
|
|
|
/// <summary>
|
|
|
|
/// 构造函数
|
|
|
|
/// </summary>
|
|
|
|
public ClientShipperReqValidator()
|
|
|
|
{
|
|
|
|
this.RuleFor(o => o.CodeName)
|
|
|
|
.NotEmpty().WithName("代码");
|
|
|
|
this.RuleFor(o => o.ShortName)
|
|
|
|
.NotEmpty().WithName("简称");
|
|
|
|
}
|
|
|
|
}
|