|
|
@ -149,7 +149,8 @@ namespace Infrastructure.Extensions
|
|
|
|
{
|
|
|
|
{
|
|
|
|
json.format = "email";
|
|
|
|
json.format = "email";
|
|
|
|
json.ui = "string";
|
|
|
|
json.ui = "string";
|
|
|
|
json.email =new {
|
|
|
|
json.email = new
|
|
|
|
|
|
|
|
{
|
|
|
|
message = "email格式错误"
|
|
|
|
message = "email格式错误"
|
|
|
|
};
|
|
|
|
};
|
|
|
|
}
|
|
|
|
}
|
|
|
@ -206,7 +207,7 @@ namespace Infrastructure.Extensions
|
|
|
|
json.maxLength = new
|
|
|
|
json.maxLength = new
|
|
|
|
{
|
|
|
|
{
|
|
|
|
max = maxLengthAttribute.Length,
|
|
|
|
max = maxLengthAttribute.Length,
|
|
|
|
message = maxLengthAttribute.GetErrorMessage(localizer, metadata.DisplayName,maxLengthAttribute.ToString())
|
|
|
|
message = maxLengthAttribute.GetErrorMessage(localizer, metadata.DisplayName, maxLengthAttribute.Length.ToString())
|
|
|
|
};
|
|
|
|
};
|
|
|
|
}
|
|
|
|
}
|
|
|
|
else if (attribute is StringLengthAttribute stringLengthAttribute)
|
|
|
|
else if (attribute is StringLengthAttribute stringLengthAttribute)
|
|
|
|