refactor: 用 @Email 和 @Mobile 注解替换了部分验证,提高了代码可读性,修改了多处错误提示信息,使其更加友好

This commit is contained in:
2025-03-27 21:21:53 +08:00
parent c130f9c0bb
commit 19639c946a
26 changed files with 60 additions and 65 deletions

View File

@@ -76,7 +76,7 @@ public class GenConfigDO implements Serializable {
*/
@Schema(description = "包名称", example = "top.continew.admin.system")
@NotBlank(message = "包名称不能为空")
@Pattern(regexp = RegexConstants.PACKAGE_NAME, message = "包名称格式错误")
@Pattern(regexp = RegexConstants.PACKAGE_NAME, message = "包名称格式不正确")
@Length(max = 60, message = "包名称不能超过 {max} 个字符")
private String packageName;