优化:优化校验注解提示信息的写法

This commit is contained in:
2023-02-16 20:54:17 +08:00
parent db345664a3
commit 56449263d3
4 changed files with 5 additions and 5 deletions

View File

@@ -73,7 +73,7 @@ public class DeptRequest extends BaseRequest {
* 描述
*/
@Schema(description = "描述")
@Length(max = 200, message = "描述长度不能超过 200 个字符")
@Length(max = 200, message = "描述长度不能超过 {max} 个字符")
private String description;
/**

View File

@@ -82,7 +82,7 @@ public class RoleRequest extends BaseRequest {
* 描述
*/
@Schema(description = "描述")
@Length(max = 200, message = "描述长度不能超过 200 个字符")
@Length(max = 200, message = "描述长度不能超过 {max} 个字符")
private String description;
/**

View File

@@ -46,7 +46,7 @@ public class UpdateBasicInfoRequest implements Serializable {
*/
@Schema(description = "昵称")
@NotBlank(message = "昵称不能为空")
@Length(max = 32, message = "昵称长度不能超过 32 个字符")
@Length(max = 32, message = "昵称长度不能超过 {max} 个字符")
private String nickname;
/**