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

31 lines
815 B

using FluentValidation;
using Kean.Domain.Order.Models;
using System.Collections.Generic;
namespace Kean.Domain.Order.Commands
{
/// <summary>
/// 修改订单命令
/// </summary>
public class ModifyOrderCommand : CommandValidator<ModifyOrderCommand>, ICommand
{
/// <summary>
/// 标识
/// </summary>
public int Id { get; set; }
/// <summary>
/// 订单行
/// </summary>
public IEnumerable<OrderLine> Lines { get; set; }
/// <summary>
/// 验证项
/// </summary>
protected override void Validation()
{
RuleFor(r => r.Id).NotEmpty().WithMessage("标识不允许空");
RuleFor(r => r.Lines).NotEmpty().WithMessage("订单行不允许空");
}
}
}