using FluentValidation; using System.Collections.Generic; namespace Kean.Domain.Basic.Commands { /// /// 删除角色命令 /// public class DeleteRoleCommand : CommandValidator, ICommand { /// /// 标识 /// public IEnumerable Id { get; set; } /// /// 验证项 /// protected override void Validation() { RuleFor(r => r.Id).NotEmpty().WithMessage("标识不允许空"); } } }