15 lines
418 B
C#
15 lines
418 B
C#
using Atomx.Admin.Client.Models;
|
|
using FluentValidation;
|
|
using Microsoft.Extensions.Localization;
|
|
|
|
namespace Atomx.Admin.Client.Validators
|
|
{
|
|
public class CountryModelValidator : AbstractValidator<CountryModel>
|
|
{
|
|
public CountryModelValidator(IStringLocalizer<CountryModelValidator> localizer)
|
|
{
|
|
RuleFor(p => p.Name).NotEmpty().WithMessage("请填名称信息");
|
|
}
|
|
}
|
|
}
|