You cannot select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

81 lines
2.0 KiB
C#

using DS.Module.Core;
using FluentValidation;
using SqlSugar;
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
namespace DS.WMS.Core.Code.Dtos
{
/// <summary>
/// 订单关系人请求
/// </summary>
public class CodeOrderContactReq
{
/// <summary>
/// 主键Id
/// </summary>
public long Id { get; set; }
/// <summary>
/// 客户类别
/// </summary>
public string CustomerType { get; set; }
/// <summary>
/// 客户Id
/// </summary>
public long CustomerId { get; set; }
/// <summary>
/// 客户名称
/// </summary>
public string CustomerName { get; set; }
/// <summary>
/// 角色代码
/// </summary>
public string RoleCode { get; set; }
/// <summary>
/// 联系人
/// </summary>
public string Name { get; set; }
/// <summary>
/// 电话
/// </summary>
public string Tel { get; set; }
/// <summary>
/// 邮箱
/// </summary>
public string Email { get; set; }
/// <summary>
/// 排序
/// </summary>
public int? OrderNo { get; set; } = 100;
/// <summary>
/// 备注
/// </summary>
public string Note { get; set; }
/// <summary>
/// 状态 0启用 1禁用
/// </summary>
public StatusEnum? Status { get; set; } = StatusEnum.Enable;
}
/// <summary>
/// 验证
/// </summary>
public class CodeOrderContactReqValidator : AbstractValidator<CodeOrderContactReq>
{
/// <summary>
/// 构造函数
/// </summary>
public CodeOrderContactReqValidator()
{
this.RuleFor(o => o.CustomerType)
.NotEmpty().WithName("客户类别");
//this.RuleFor(o => o.SendType)
// .NotEmpty().WithName("发送类型");
}
}
}